mirror of
https://github.com/t4t5/nostr-react.git
synced 2025-09-17 13:18:54 +02:00
Add "debug" option to NostrProvider
This commit is contained in:
@@ -38,9 +38,11 @@ const NostrContext = createContext<NostrContextType>({
|
|||||||
export function NostrProvider({
|
export function NostrProvider({
|
||||||
children,
|
children,
|
||||||
relayUrls,
|
relayUrls,
|
||||||
|
debug,
|
||||||
}: {
|
}: {
|
||||||
children: ReactNode;
|
children: ReactNode;
|
||||||
relayUrls: string[];
|
relayUrls: string[];
|
||||||
|
debug?: boolean;
|
||||||
}) {
|
}) {
|
||||||
const [isLoading, setIsLoading] = useState(true);
|
const [isLoading, setIsLoading] = useState(true);
|
||||||
|
|
||||||
@@ -64,7 +66,7 @@ export function NostrProvider({
|
|||||||
onEventCallback(relayUrl, event);
|
onEventCallback(relayUrl, event);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
debug: true,
|
debug,
|
||||||
});
|
});
|
||||||
|
|
||||||
sendEventRef.current = _sendEvent;
|
sendEventRef.current = _sendEvent;
|
||||||
|
Reference in New Issue
Block a user