Skip to content
Source
Sign inSign up
TanStack/query
Open History to see the last commit

theme.tsx

13 lines272 Bytes

1// @ts-nocheck
2​
3import React from 'react'
4​
5const ThemeContext = React.createContext()
6​
7export function ThemeProvider({ theme, ...rest }) {
8 return <ThemeContext.Provider value={theme} {...rest} />
9}
10​
11export function useTheme() {
12 return React.useContext(ThemeContext)