Refactor scene management with store
This commit is contained in:
parent
f9079e4823
commit
871b4116ff
10 changed files with 69 additions and 59 deletions
12
src/store.ts
Normal file
12
src/store.ts
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
import create from 'zustand/vanilla';
|
||||
import { Scenes } from './scenes/scenes';
|
||||
|
||||
export interface State {
|
||||
currentScene: Scenes;
|
||||
}
|
||||
|
||||
const store = create<State>(() => ({
|
||||
currentScene: Scenes.OVERVIEW,
|
||||
}));
|
||||
|
||||
export default store;
|
||||
Reference in a new issue