forked from kriasoft/aspnet-starter-kit
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstore.js
More file actions
24 lines (21 loc) · 640 Bytes
/
store.js
File metadata and controls
24 lines (21 loc) · 640 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
/**
* ASP.NET Core Starter Kit (https://dotnetreact.com)
*
* Copyright © 2014-present Kriasoft, LLC. All rights reserved.
*
* This source code is licensed under the MIT license found in the
* LICENSE.txt file in the root directory of this source tree.
*/
import { createStore } from 'redux';
// Centralized application state
// For more information visit http://redux.js.org/
const store = createStore((state, action) => {
// TODO: Add action handlers (aka "reduces")
switch (action) {
case 'COUNT':
return { ...state, count: (state.count || 0) + 1 };
default:
return state;
}
});
export default store;