javascript - Getting query parameters from react-router hash fragment -


i'm using react , react-router application on client side. can't seem figure out how following query parameters url like:

http://xmen.database/search#/?status=approved&page=1&limit=20 

my routes (the path totally wrong know):

var routes = ( <route>     <defaultroute handler={searchdisplay}/>     <route name="search" path="?status=:status&page=:page&limit=:limit" handler={searchdisplay}/>     <route name="xmen" path="candidate/:accountid" handler={xmendisplay}/> </route> ); 

my route working fine i'm not sure how format path parameters want. appreciate on this!

note: copy / pasted comment. sure original post!

writing in es6 , using react 0.14.6 / react-router 2.0.0-rc5. use command lookup query params in components:

this.props.location.query 

it creates hash of available query params in url.


Comments

Popular posts from this blog

shopping cart - Page redirect not working PHP -

php - How to modify a menu to show sub-menus -

python - Installing PyDev in eclipse is failed -