I advise everyone to move away from React Router. Maintainers who have such blatant disregard for users should not be rewarded or celebrated.
React Router v5
41–50 of 90 posts
Re: React Router v5
#42We migrated from React Router to Reach Router ( https://reach.tech/router ) and found it to be better in a few ways: * Built-in focus management. * Smaller library size. * Implicit route matching that Just Works. * More comprehensive docs with live examples. Migration was easy. Highly recommended.
We did the same thing, then migrated back to React-Router. We had issues getting relative urls and redirects to work, examples were hard to come by, and generally the experience was just poorer than React-Router.
Re: React Router v5
#43I advise everyone to move away from React Router. Maintainers who have such blatant disregard for users should not be rewarded or celebrated.
Re: React Router v5
#44Re: React Router v5
#45I migrated away from react-router because from v3 to v4 broke everything that made sense. Things became wildly more complicated. I'm now extremely happy with my new router of choice router5 (not to be confused with React Router 5) https://router5.js.org .
1. Having to write middleware for many things is quite hard for junior devs, as it requires deep understanding of how router works. (We have middleware for dependency injection, MobX per-page store, data fetching, auth check)
2. Due to the tree-based router design, some routes are impossible. See https://github.com/troch/route-node/issues/17 https://github.com/troch/route-node/issues/18
I still haven't found router of my choice yet. Maybe router5 without route-note could work for me, but I still wouldn't recommend it to any team.
Re: React Router v5
#46We migrated from React Router to Reach Router ( https://reach.tech/router ) and found it to be better in a few ways: * Built-in focus management. * Smaller library size. * Implicit route matching that Just Works. * More comprehensive docs with live examples. Migration was easy. Highly recommended.
Re: React Router v5
#47I migrated away from react-router because from v3 to v4 broke everything that made sense. Things became wildly more complicated. I'm now extremely happy with my new router of choice router5 (not to be confused with React Router 5) https://router5.js.org .
I wrote 2 articles about it in case it can help someone:
- https://www.vincentprouillet.com/blog/testing-a-different-sp...
- https://www.vincentprouillet.com/blog/testing-a-different-sp...
It probably changed a bit since those articles but I was happy with it. A very simple codebase using that can be seen on https://github.com/Keats/hn-react
Re: React Router v5
#48On 10 June 2017, an mind-bogglingly ill-conceived pull request[1] was merged, which causes invalid URLs to be pushed to the browser history, breaking the back button and page refresh in many scenarios.
Ever since, users have practically been begging the maintainer to fix the bug[2] and implementing hacky workarounds[3].
In a twist of irony, the contributor who originally introduced the bug has:
a) switched their own competing router package to a different history implementation[4]
b) argued that fixing the bug (which was introduced in a patch release) would require a major version bump, implying it would be better to let it remain broken[5].
I concede that the software is open source, and nobody is entitled to make any demands of the maintainers. Nevertheless, I pity the countless end-users who are left wondering why the most basic functionality of their web browsers is broken.
[1]: https://github.com/ReactTraining/history/pull/465
[2]: https://github.com/ReactTraining/history/issues/505
[3]: https://github.com/elastic/kibana/pull/32365
[4]: https://github.com/pshrmn/curi/commit/e850bcd9297398653a79b9...
Re: React Router v5
#49Using react router on one of my personal projects (~ 30k loc) was probably one of my largest regrets. At every turn it seemed designed to do the thing I wouldn’t expect, or have arbitrary restrictions that made my life tougher. Some examples: * there's no relative routes https://github.com/ReactTraining/react-router/issues/2172 * there's no way to refresh the page https://github.com/ReactTraining/react-router/issues/…
Yup. I only use react-router when I have to (work). My other projects I always roll my own. A typical html5 push router can be really small. I don’t reinvent the wheel normally but routing is hugely overcomplicated in the react ecosystem.
Re: React Router v5
#50I advise everyone to move away from React Router. Maintainers who have such blatant disregard for users should not be rewarded or celebrated.
I think that when someone provides an open source project they are doing everyone a favour. We then have a choice not to use it. But using their free thing is certainly not doing them a favour unless we are somehow contributing back.