UNPKG

threed-ai

Version:

'threed-ai' supporting Vite, Next, Nuxt, as a functioning, low-dependency app, a package supporting monorepos of workspaces that utilize 'ThreeJS, WebGL, React, TypeScript <r3Fiber>, GraphQL'.

18 lines (13 loc) 368 B
import create from 'zustand' import { shallow } from 'zustand/shallow' const useStoreImpl = create(() => { return { router: null, dom: null, } }) const useStore = (sel) => useStoreImpl(sel, shallow) Object.assign(useStore, useStoreImpl) const { getState, setState } = useStoreImpl export { getState, setState } export default useStore