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
Show how active nav item would be specified and displayed with react router #94
Comments
I created an issue that I hope describes the problem and possible solutions reasonably well: remix-run/react-router#6390 |
How do other component libraries handle this? |
Good question, my current answer is no idea - if there are any you can think of off the top of your head spam me here/in slack and I'll have a look. Otherwise I'll try find some to look at. edit: adequately named link; https://blog.bitsrc.io/11-react-component-libraries-you-should-know-178eb1dd6aa4 |
There’s a list in our readme. I’m planning to review this afternoon |
Cool, just for anyone else; https://github.com/UKHomeOffice/govuk-react#other-react-component-libraries |
Summary of approaches Approachesas prophttps://www.styled-components.com/docs/api#as-polymorphic-prop LibsRebassUses an "as" prop
https://github.com/rebassjs/rebass/blob/master/src/index.js#L101-L108 |
Please support how an active nav item would be specified and displayed.
Possibly not a contender for context api as we'd probably expect something further up to be managing the routing and telling us what is active. But worth a thought.
Copied from
#93 (comment)
The text was updated successfully, but these errors were encountered: