inception: add openpanel to openpanel 🥷
This commit is contained in:
@@ -19,6 +19,7 @@
|
||||
"@openpanel/common": "workspace:^",
|
||||
"@openpanel/constants": "workspace:^",
|
||||
"@openpanel/db": "workspace:^",
|
||||
"@openpanel/nextjs": "0.0.8-beta",
|
||||
"@openpanel/queue": "workspace:^",
|
||||
"@openpanel/validation": "workspace:^",
|
||||
"@radix-ui/react-accordion": "^1.1.2",
|
||||
|
||||
@@ -14,8 +14,10 @@ import { Provider as ReduxProvider } from 'react-redux';
|
||||
import { Toaster } from 'sonner';
|
||||
import superjson from 'superjson';
|
||||
|
||||
import { OpenpanelProvider } from '@openpanel/nextjs';
|
||||
|
||||
function AllProviders({ children }: { children: React.ReactNode }) {
|
||||
const { getToken } = useAuth();
|
||||
const { getToken, userId } = useAuth();
|
||||
const [queryClient] = useState(
|
||||
() =>
|
||||
new QueryClient({
|
||||
@@ -54,6 +56,12 @@ function AllProviders({ children }: { children: React.ReactNode }) {
|
||||
defaultTheme="light"
|
||||
disableTransitionOnChange
|
||||
>
|
||||
<OpenpanelProvider
|
||||
clientId="7f1a992c-12bf-4def-b636-4aee3139e85d"
|
||||
profileId={userId || undefined}
|
||||
trackScreenViews
|
||||
trackOutgoingLinks
|
||||
/>
|
||||
<ReduxProvider store={storeRef.current}>
|
||||
<api.Provider client={trpcClient} queryClient={queryClient}>
|
||||
<QueryClientProvider client={queryClient}>
|
||||
|
||||
Reference in New Issue
Block a user