2021-05-10 16:41:58 +10:00

10 lines
266 B
TypeScript

import { createContext, useContext } from 'react';
import { Waku } from 'waku';
export type WakuContextType = {
waku?: Waku;
};
export const WakuContext = createContext<WakuContextType>({ waku: undefined });
export const useWaku = () => useContext(WakuContext);