mirror of
https://gitlab.com/soapbox-pub/mkstack.git
synced 2026-12-05 08:23:35 +00:00
Refactor AppProvider
This commit is contained in:
9 files changed
+156
-204
No files matched your search
@@ -3,6 +3,7 @@ import { QueryClient, QueryClientProvider } from '@tanstack/react-query';
|
||||
import { NostrLoginProvider } from '@nostrify/react/login';
|
||||
import NostrProvider from '@/components/NostrProvider';
|
||||
import { AppProvider } from '@/components/AppProvider';
|
||||
import { AppConfig } from '@/contexts/AppContext';
|
||||
|
||||
interface TestAppProps {
|
||||
children: React.ReactNode;
|
||||
@@ -16,9 +17,14 @@ export function TestApp({ children }: TestAppProps) {
|
||||
},
|
||||
});
|
||||
|
||||
const defaultConfig: AppConfig = {
|
||||
theme: 'light',
|
||||
relayUrl: 'wss://relay.nostr.band',
|
||||
};
|
||||
|
||||
return (
|
||||
<BrowserRouter>
|
||||
<AppProvider>
|
||||
<AppProvider storageKey='test-app-config' defaultConfig={defaultConfig}>
|
||||
<QueryClientProvider client={queryClient}>
|
||||
<NostrLoginProvider storageKey='test-login'>
|
||||
<NostrProvider>
|
||||
|
||||
Reference in new issue
Block a user