Skip to content

Commit 2029fd3

Browse files
committed
Fix TypeScript error for window.nostr after NDK removal
- Add back global Window interface declaration for nostr property - Defines window.nostr as optional NostrProvider type - Fixes TypeScript compilation error in LoginForm and other components - Required after removing NDK which previously provided these types
1 parent 8fd1f5a commit 2029fd3

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

src/types/nostr.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,5 +13,9 @@ export interface NostrProvider {
1313
};
1414
}
1515

16-
// Global Window declaration removed to avoid conflict with NDK types
17-
// NDK will provide the window.nostr types automatically
16+
// Global Window declaration for Nostr extension
17+
declare global {
18+
interface Window {
19+
nostr?: NostrProvider;
20+
}
21+
}

0 commit comments

Comments
 (0)