reactjs - Can I use an HTML form's action property to move between React Routes? -
i'm trying build react app, , getting trouble react router. first of all, url has weird hashstring @ its' end. example: http://localhost:3000/#/?_k=gb3epe
also, i'm not sure whether hashtag in url , following gibberish part of same problem or if they're related 2 different problems. (i'm using react-router v1.0).
secondly, think weird url preventing me using "action" property on forms, , know if there better way move around react renders relaying on forms.
thanks.
if we're talking react-router v1.0
, remove hash string should pass { querykey: false }
parameter createbrowserhistory function.
var createbrowserhistory = require('history/lib/createbrowserhistory'); reactdom.render( <router history={ createbrowserhistory({ querykey: false }) } routes={ reactroutes } />, document.getelementbyid('some-container') );
to move between routes react-router
provides link
component can use inside components.
Comments
Post a Comment