Files
Charon/frontend/src/context/ThemeContextValue.ts

11 lines
240 B
TypeScript

import { createContext } from 'react'
export type Theme = 'dark' | 'light'
export interface ThemeContextType {
theme: Theme
toggleTheme: () => void
}
export const ThemeContext = createContext<ThemeContextType | undefined>(undefined)