-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapp.js
More file actions
52 lines (44 loc) · 912 Bytes
/
app.js
File metadata and controls
52 lines (44 loc) · 912 Bytes
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
40
41
42
43
44
45
46
47
48
49
50
51
52
// vendor
import React from 'react'
import { fromJS } from 'immutable'
import { Provider } from 'react-redux'
import { getRoutes } from './routes'
import initRaygun from 'util/initRaygun'
import configureStore from './store/configureStore'
import {
render
} from 'react-dom'
import {
Router,
browserHistory
} from 'react-router'
import { hideModal } from 'reporting/actions/modal'
const {
VO_CONFIG,
VO_ENV,
VO_ROUTES
} = window
const store = configureStore({
auth: {
config: fromJS(VO_CONFIG),
env: fromJS(VO_ENV),
routes: fromJS(VO_ROUTES)
}
})
initRaygun()
async function onUpdate () {
store.dispatch(hideModal())
}
export default function () {
render(
<Provider store={store}>
<Router
history={browserHistory}
onUpdate={onUpdate}
>
{ getRoutes() }
</Router>
</Provider>,
document.getElementById('reporting')
)
}