mirror of
https://github.com/TheRealOwenRees/echecsfrance.git
synced 2026-07-23 04:26:57 +00:00
type errors fixed
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
import { useEffect, useState } from "react";
|
import { Dispatch, SetStateAction, useEffect, useState } from "react";
|
||||||
|
|
||||||
function useDarkMode() {
|
function useDarkMode(): [string, Dispatch<SetStateAction<string>>] {
|
||||||
const [theme, setTheme] = useState(
|
const [theme, setTheme] = useState(
|
||||||
typeof window !== "undefined" ? localStorage.theme : "dark"
|
typeof window !== "undefined" ? localStorage.theme : "dark"
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in New Issue
Block a user