Commit f5624a13 authored by Jure's avatar Jure

Merge branch 'routes-as-prop' into 'master'

Accept routes element as a prop instead of requiring from app

Closes #40

See merge request !109
parents cd6d84bb b84c20ea
Pipeline #2621 passed with stage
in 1 minute and 40 seconds
......@@ -3,11 +3,9 @@ import { ConnectedRouter } from 'react-router-redux'
import { Provider } from 'react-redux'
import PropTypes from 'prop-types'
import routes from 'app/routes'
export default class Root extends React.Component {
render () {
const { store, history } = this.props
const { store, history, routes } = this.props
return (
<Provider store={store}>
<div>
......@@ -21,6 +19,7 @@ export default class Root extends React.Component {
}
Root.propTypes = {
routes: PropTypes.node.isRequired,
history: PropTypes.object.isRequired,
store: PropTypes.object.isRequired
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment