mirror of
https://github.com/YMFE/yapi.git
synced 2024-12-15 05:10:47 +08:00
fix: create and app bug
This commit is contained in:
parent
005224b54e
commit
ea640b2fd6
@ -1,7 +1,7 @@
|
|||||||
import React, { Component } from 'react';
|
import React, { Component } from 'react';
|
||||||
import { connect } from 'react-redux';
|
import { connect } from 'react-redux';
|
||||||
import PropTypes from 'prop-types';
|
import PropTypes from 'prop-types';
|
||||||
import { Route, BrowserRouter as Router, Redirect, Switch } from 'react-router-dom';
|
import { Route, BrowserRouter as Router } from 'react-router-dom';
|
||||||
import { Home, Group, Project, Follows, AddProject } from './containers/index';
|
import { Home, Group, Project, Follows, AddProject } from './containers/index';
|
||||||
import User from './containers/User/User.js';
|
import User from './containers/User/User.js';
|
||||||
import Header from './components/Header/Header';
|
import Header from './components/Header/Header';
|
||||||
|
@ -2,7 +2,7 @@ import { createStore as _createStore, applyMiddleware, compose } from 'redux';
|
|||||||
import thunkMiddleware from 'redux-thunk';
|
import thunkMiddleware from 'redux-thunk';
|
||||||
import promiseMiddleware from 'redux-promise';
|
import promiseMiddleware from 'redux-promise';
|
||||||
import messageMiddleware from './middleware/messageMiddleware';
|
import messageMiddleware from './middleware/messageMiddleware';
|
||||||
|
import DevTools from '../containers/DevTools/DevTools'
|
||||||
import reducer from './modules/reducer';
|
import reducer from './modules/reducer';
|
||||||
|
|
||||||
export default function createStore(initialState = {}) {
|
export default function createStore(initialState = {}) {
|
||||||
@ -12,7 +12,7 @@ export default function createStore(initialState = {}) {
|
|||||||
if (ENV_PARAMS.development) {
|
if (ENV_PARAMS.development) {
|
||||||
finalCreateStore = compose(
|
finalCreateStore = compose(
|
||||||
applyMiddleware(...middleware),
|
applyMiddleware(...middleware),
|
||||||
window.devToolsExtension ? window.devToolsExtension() : require('../cntainers/DevTools/DevTools').default.instrument()
|
window.devToolsExtension ? window.devToolsExtension() : DevTools.instrument()
|
||||||
)(_createStore);
|
)(_createStore);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user