2.2.0 • Published 5 years ago

redux-store-init v2.2.0

Weekly downloads
5
License
MIT
Repository
github
Last release
5 years ago

redux-store-init

redux-store-init is a function used to initialize store.

install

npm install --save redux-store-init

use

import React from 'react';
import { hydrate } from 'react-dom';
import { Provider } from 'react-redux';
import * as reducers from './reducers';
import Store from 'redux-store-init';

import thunk from 'redux-thunk';
import logger from 'redux-diff-logger';

const store = Store({ reducers, devtool: true, applyMiddlewares: [thunk, logger] });
// or
// Store({ reducers, devtool: true }, [thunk, logger]);

hydrate(
    <Provider store={store}>
        <App />
    </Provider>,
    document.getElementById('app')
);

options

  • devtool: Boolean
  • reducers: Object
  • compose: Array
  • initState: Object
  • applyMiddlewares: Array
2.2.0

5 years ago

2.1.0

5 years ago

2.0.0

6 years ago

1.5.1

6 years ago

1.5.0

6 years ago

1.4.1

6 years ago

1.4.0

6 years ago

1.3.2

6 years ago

1.3.1

6 years ago

1.3.0

6 years ago

1.2.6

6 years ago

1.2.5

6 years ago

1.2.4

6 years ago

1.2.3

6 years ago

1.2.2

6 years ago

1.2.1

6 years ago

1.2.0

6 years ago

1.1.1

6 years ago

1.1.0

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago