Update text.md

Added a suggestion for a user to add the preventDefault modifier so they could press any key uninterrupted by the default behavior of a key or key combination.
pull/3270/head
Philipp_Lypniakov 5 years ago committed by GitHub
parent 03849825bb
commit b3b830d21a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -8,4 +8,9 @@ On line 33, add the `keydown` listener:
```html
<svelte:window on:keydown={handleKeydown}/>
```
```
Don't forget to add `preventDefault` modifier if you want to press any other key, e.g. after you have pressed `Tab` or `Ctrl + D`:
```html
<svelte:window on:keydown|preventDefault={handleKeydown}/>
```

Loading…
Cancel
Save