Export toggle switch to new component file

Refactored for future code maintainability. Also added in default to dark theme and adjusted some styling on the toggle switch.
This commit is contained in:
Nick Bland
2022-04-24 00:19:38 +10:00
parent 71563f316d
commit 4337801152
3 changed files with 36 additions and 47 deletions
+1 -1
View File
@@ -5,7 +5,7 @@ import {ThemeProvider} from 'next-themes'
function MyApp({ Component, pageProps }: AppProps) {
return (
<>
<ThemeProvider attribute="class">
<ThemeProvider attribute="class" defaultTheme="dark">
<Component {...pageProps} />
</ThemeProvider>
</>