NPM Module (recommended)

Seedux can be easily installed as a developer dependency with npm using your favorite terminal.

npm install seedux --save-dev

Development Version

For a codebase suitable for modification, clone our git repository to an easily accessible file path on your computer and run the build:

cd seedux_repo_path

npm install

npm run build:both

Getting Started:

Import combineReducers, connect, and bindActionCreators from Seedux, rather than Redux/React-Redux. The examples below assume you are working with the npm module. If you are working from the git repo, replace 'seedux' with your repo path!

// import { combineReducers } from 'redux';

import{combineReducers}from'seedux';

// import { connect } from 'react-redux';

import{connect}from'seedux';

Note: Seedux relies on bindActionCreators to parse your action types at runtime and provide visual feedback on dispatched actions. If you are not using bindActionCreators, you can pass your actions directly to seeduxInit instead.

// import { bindActionCreators } from 'redux';

import{bindActionCreators}from'seedux';

Import dispatchLogger from Seedux and apply it as middleware when invoking createStore.

Import and call seeduxInit. Pass seeduxInit your newly created store (and actionCreators if not using bindActionCreators).

Complete Example Integration

The following import examples are for the npm package. Replace <'seedux'> with your Seedux repo filepath to use the development version.

Import dispatchLogger from Seedux and replace Redux's createStore function with Seedux's version. Invoke createStore as normal with applyMiddleware(dispatchLogger) as the third argument. Invoke seeduxInit with your store (and actionCreators, if not using bindActionCreators).