Skip to content

Commit

Permalink
feat: add next theme context
Browse files Browse the repository at this point in the history
  • Loading branch information
rikhall1515 committed Apr 19, 2024
1 parent 166b934 commit e5289fe
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions context/theme.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
"use client";

import { ThemeProvider } from "next-themes";
export default function ThemeContextProvider({
children,
}: {
children: React.ReactNode;
}) {
return (
<>
<ThemeProvider attribute="class" defaultTheme="system" enableSystem>
{children}
</ThemeProvider>
</>
);
}

0 comments on commit e5289fe

Please sign in to comment.