mirror of
https://github.com/nextui-org/nextui.git
synced 2025-12-08 19:26:11 +00:00
20 lines
526 B
TypeScript
20 lines
526 B
TypeScript
"use client";
|
|
|
|
import * as React from "react";
|
|
import {NextUIProvider} from "@nextui-org/react";
|
|
import {ThemeProvider as NextThemesProvider} from "next-themes";
|
|
import {ThemeProviderProps} from "next-themes/dist/types";
|
|
|
|
export interface ProvidersProps {
|
|
children: React.ReactNode;
|
|
themeProps?: ThemeProviderProps;
|
|
}
|
|
|
|
export function Providers({children, themeProps}: ProvidersProps) {
|
|
return (
|
|
<NextUIProvider>
|
|
<NextThemesProvider {...themeProps}>{children}</NextThemesProvider>
|
|
</NextUIProvider>
|
|
);
|
|
}
|