index.js
1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import React from 'react'
import ReactDOM from 'react-dom'
import Spd from './containers/Spd'
import {
HashRouter as Router,
Route
} from 'react-router-dom'
import RegionalDesign from './components/RegionalDesign'
import { applyMiddleware, createStore } from 'redux'
import { Provider, connect } from 'react-redux'
import rootReducer from './reducers'
import createSagaMiddleware from 'redux-saga'
import { helloSaga } from './sagas/header'
import configureStore from './store/configureStore'
const sagaMiddleware = createSagaMiddleware()
const store = configureStore()
// const store = createStore(rootReducer, applyMiddleware(sagaMiddleware, logger), window.__REDUX_DEVTOOLS_EXTENSION__ && window.__REDUX_DEVTOOLS_EXTENSION__())
// store.runSaga(helloSaga)
ReactDOM.render(
<Provider store={store}>
<Router handler={Spd} history={Router}>
<Spd>
<Route path="/web/regional_design/:id" component={RegionalDesign} />
</Spd>
</Router>
</Provider>,
document.getElementById('root')
);