i have route config similar this:
<route path="/"> <route component={books} path="books" /> <route component={bookdetail} path="books/:bookid" /> </route>
is possible highlight link
active points /books
when /books/:bookid
active?
i know can achieved making /books/:bookid
child of /books
, i'd avoid bookdetail
replaces books
in view.
my current solution bookdetail
child of books
, books
has condition render either when route active or otherwise children. i'd avoid if possible.
not sure if understand well, don't have enough point post comment. can pass parameter
<route path="/"> <route component={books} path="books" /> <route component={bookdetail} path="books/:bookid" isdetail={true} /> </route>
Comments
Post a Comment