import React, { PropsWithChildren, useContext } from 'react'; type ActiveChannels = React.MutableRefObject; const ActiveChannelsContext = React.createContext({ current: [] } as ActiveChannels); export const ActiveChannelsProvider = ({ children, value, }: PropsWithChildren<{ value: ActiveChannels; }>) => {children}; export const useActiveChannelsRefContext = () => useContext(ActiveChannelsContext) as unknown as ActiveChannels;