1 2 3 4 5 6 7 8 9 10 11 12
import { observable } from 'mobx'; const defaultState = { isLoading: false, workspaces: [], }; export const state = observable(defaultState); export function resetState() { Object.assign(state, defaultState); }