Javascript – Need to store React Functional component in react useState hook
I want to store React component in react useState but i think it is technically is wrong. What you think about that. Example const LayoutContext = createContext(null as unknown as { setSidebarContent: React.Dispatch<React.SetStateAction<null | React.ReactNode>>; }) const Layout = ()…