static Store <AppState> CreateStore()
        {
            var shareState = JsonUtility.FromJson <AppState>(SessionState.GetString(typeof(ShareWindow).Name, "{}"));

            return(new Store <AppState>(ShareReducer.reducer, shareState, ShareMiddleware.Create()));
        }
Esempio n. 2
0
        static void SetupStore()
        {
            var shareState = new ShareState();

            EditorJsonUtility.FromJsonOverwrite(SessionState.GetString(typeof(ConnectShareEditorWindow).Name, "{}"), shareState);

            _store = new Store <AppState>(ShareReducer.reducer, new AppState(shareState), ShareMiddleware.Create());
        }