space-shuffler / components /toggle-mode.tsx
enzostvs's picture
enzostvs HF staff
initial commit
f70bb71
raw
history blame contribute delete
285 Bytes
import { useTheme } from "next-themes";
export const ToggleMode = () => {
const { setTheme } = useTheme();
return (
<div>
<button onClick={() => setTheme("light")}>Light Mode</button>
<button onClick={() => setTheme("dark")}>Dark Mode</button>
</div>
);
};