Skip to content

Commit d85b620

Browse files
committed
fix: attempt removing throttle dep
1 parent ac1dabc commit d85b620

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/lib/components/generic/KeyControls.svelte

+1-3
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
<script>
22
import { KEY_CODES } from '$lib/config';
33
import { keyControlsContextKey } from '$lib/context';
4-
import throttle from 'just-throttle';
54
import { getContext } from 'svelte';
65
7-
export let limit = 0;
86
export let ctx = null;
97
108
const currentCtx = getContext(keyControlsContextKey);
@@ -15,7 +13,7 @@
1513
if (mapping) mapping();
1614
};
1715
18-
$: eventHandler = limit ? throttle(key, limit) : key;
16+
$: eventHandler = key;
1917
</script>
2018

2119
<svelte:window on:keydown={eventHandler} />

0 commit comments

Comments
 (0)