Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

random string in link address #315

Closed
uragecz opened this issue Aug 1, 2016 · 2 comments
Closed

random string in link address #315

uragecz opened this issue Aug 1, 2016 · 2 comments

Comments

@uragecz
Copy link

uragecz commented Aug 1, 2016

How i can get clean link path? I past into address localhost:3000/ and all time it automaticle fill address with some random chars, for example - http://localhost:3000/#/?_k=s3lc0a ... after click on any link in my menu its chaning on http://localhost:3000/#/graph?_k=z6exsl .... my index.js looks like -

ReactDOM.render(
    <Router>
        <Route path="/" component={App}>
            <IndexRoute component={Home} />
            <Route path="/graph" component={Print}/>
         </Route>
    </Router>,document.getElementById('root')

And link in menu - <li><Link to="/graph" activeClassName="active">{data.graph}</Link></li>
Any tips what i have to do pls ? i want just have an address like a - localhost:3000/graph ...

@insin
Copy link
Contributor

insin commented Aug 1, 2016

See What is that ?_k=ckuvup junk in the URL? in the React Router documentation.

Use browserHistory instead to avoid it: example in the same documention.

@gaearon
Copy link
Contributor

gaearon commented Aug 1, 2016

This is a question about React Router and not related to this project. Thanks @insin for answering! (By the way you don't have to use React Router if you don't like it, you can use vanilla HTML5 history API just fine if that's what you prefer.)

@gaearon gaearon closed this as completed Aug 1, 2016
linhaobin pushed a commit to linhaobin/create-react-app-hb that referenced this issue May 21, 2018
@lock lock bot locked and limited conversation to collaborators Jan 23, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants