1
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import React, { createContext, useState, useContext, useEffect } from "react";
|
||||
import { createContext, useState, useContext, useEffect, type FC, type ReactNode } from "react";
|
||||
|
||||
type Theme = "light" | "dark";
|
||||
|
||||
@@ -9,7 +9,7 @@ type ThemeContextType = {
|
||||
|
||||
const ThemeContext = createContext<ThemeContextType | undefined>(undefined);
|
||||
|
||||
export const ThemeProvider: React.FC<{ children: React.ReactNode }> = ({
|
||||
export const ThemeProvider: FC<{ children: ReactNode }> = ({
|
||||
children,
|
||||
}) => {
|
||||
const [theme, setTheme] = useState<Theme>("light");
|
||||
|
||||
Reference in New Issue
Block a user