1.0.4 • Published 6 years ago

redux-go v1.0.4

Weekly downloads
4
License
ISC
Repository
github
Last release
6 years ago

Redux-go

Some redux helpers.

Usage

import { createAction, createReducer } from 'redux-go';

// define action
const changeData = createAction('changeData');

// define init state
const appState = { name: '' };

// define reducer 
const reducer = createReducer({
    [changeData]: (state, action) => {
        return {...state, name: action.payload};
    },
}, appState);

// dispatch action
dispatch(changeData('tom'))
1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago