woocommerce/plugins/woocommerce-admin/client/wc-api/wp-data-store/create-store.js

17 lines
327 B
JavaScript

/** @format */
/**
* External dependencies
*/
import { createStore } from 'redux';
/**
* Internal dependencies
*/
import reducer from './reducer';
export default name => {
const devTools = window.__REDUX_DEVTOOLS_EXTENSION__;
return createStore( reducer, devTools && devTools( { name: name, instanceId: name } ) );
};