From 85f841968200316958d707db0c39bb115f762471 Mon Sep 17 00:00:00 2001 From: Trevor Fitzgerald Date: Wed, 27 Dec 2023 08:39:05 -0500 Subject: [PATCH] fix(fs): Fix DebouncedEvent type to match what notify-rs returns (#848) * fix(fs): Fix DebouncedEvent type to match what notify-rs returns * Update fix-debounced-event-type.md --- .changes/fix-debounced-event-type.md | 5 +++++ plugins/fs/guest-js/index.ts | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) create mode 100644 .changes/fix-debounced-event-type.md diff --git a/.changes/fix-debounced-event-type.md b/.changes/fix-debounced-event-type.md new file mode 100644 index 000000000..2563827d5 --- /dev/null +++ b/.changes/fix-debounced-event-type.md @@ -0,0 +1,5 @@ +--- +"fs-js": patch +--- + +Fix `DebouncedEvent` type to correctly represent the actual type. diff --git a/plugins/fs/guest-js/index.ts b/plugins/fs/guest-js/index.ts index 1e1c0e605..3fa00f289 100644 --- a/plugins/fs/guest-js/index.ts +++ b/plugins/fs/guest-js/index.ts @@ -1127,8 +1127,8 @@ type RawEventKind = * @since 2.0.0 */ type DebouncedEvent = - | { kind: "any"; path: string } - | { kind: "AnyContinous"; path: string }; + | { kind: "Any"; path: string }[] + | { kind: "AnyContinuous"; path: string }[]; /** * @since 2.0.0