React-router: Location "/" did not match any routes

Created on 1 Aug 2016  Â·  1Comment  Â·  Source: ReactTraining/react-router

I saw a lot of solutions, but nothing helped me. I am still getting error `Warning: [react-router] Location "/" did not match any routesin my index.js-

import { Router, Route, Redirect, browserHistory } from 'react-router'; 
ReactDOM.render(<Router history={browserHistory} >{routes}</Router>, document.getElementById("app"));

    module.exports = (
        <Route path="/" handler={App}>
           <Redirect from="/" to="/graph"/>
            <Route path="/graph" handler={Pages["Graph"]}/>
        </Route>
    );

then in App.js

return (
            <div className="App-Master">
                <Header data={this.state.data.header} />
                <Navigation data={this.state.data.menu} switchLanguage={this.switchLanguage.bind(this)} />
                <div className="content">
                    {this.props.children}
                </div>
            </div>
        );

I have no links yet. This error i am getting during first loading page..

"dependencies": {
    "react": "^15.2.1",
    "react-dom": "^15.2.1",
    "react-router": "^2.6.0"
  },

>All comments

It looks like you're just getting started with React Router. Take a look at our tutorial and the guides on the site. The issue tracker is intended to track bugs and feature requests – it's not an ideal resource for learning how to use React Router.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

sarbbottam picture sarbbottam  Â·  3Comments

nicolashery picture nicolashery  Â·  3Comments

jzimmek picture jzimmek  Â·  3Comments

andrewpillar picture andrewpillar  Â·  3Comments

ArthurRougier picture ArthurRougier  Â·  3Comments