completed project, base structure to create more templates

This commit is contained in:
Amruth Pillai
2020-03-25 16:38:36 +05:30
parent d5dcd38edb
commit 7bec7b5d49
7 changed files with 54 additions and 20 deletions

View File

@ -96,6 +96,9 @@ const reducer = (state, { type, payload }) => {
return set({ ...state }, `data.${payload.key}.items`, items);
case 'on_input':
return set({ ...state }, payload.key, payload.value);
case 'save_data':
localStorage.setItem('state', JSON.stringify(state));
return state;
case 'import_data':
return {
...state,