chitchatter/src/ShellContext.ts

14 lines
358 B
TypeScript
Raw Normal View History

2022-08-28 21:25:49 -05:00
import { createContext, Dispatch, SetStateAction } from 'react'
interface ShellContextProps {
setTitle: Dispatch<SetStateAction<string>>
2022-08-29 22:05:56 -05:00
setNumberOfPeers: Dispatch<SetStateAction<number>>
numberOfPeers: number
2022-08-28 21:25:49 -05:00
}
export const ShellContext = createContext<ShellContextProps>({
setTitle: () => {},
2022-08-29 22:05:56 -05:00
setNumberOfPeers: () => {},
numberOfPeers: 1,
2022-08-28 21:25:49 -05:00
})