1
0
mirror of https://github.com/BoostIo/Boostnote synced 2026-02-18 02:11:01 +00:00

use new api for finder

This commit is contained in:
Dick Choi
2016-09-08 18:16:37 +09:00
parent 519ea1a33f
commit 40fc63ea0c
7 changed files with 76 additions and 52 deletions

View File

@@ -30,17 +30,20 @@ const defaultConfig = {
}
}
function storages (state = [], action) {
switch (action.type) {
case 'THROTTLE_DATA':
state = action.storages
}
return state
let defaultData = {
storageMap: {},
noteMap: {},
starredSet: [],
storageNoteMap: {},
folderNoteMap: {},
tagNoteMap: {}
}
function notes (state = [], action) {
function data (state = defaultData, action) {
switch (action.type) {
case 'THROTTLE_DATA':
state = action.notes
console.log(action)
state = action.data
}
return state
}
@@ -66,8 +69,7 @@ function config (state = defaultConfig, action) {
}
let reducer = combineReducers({
storages,
notes,
data,
config,
routing: routerReducer
})