Releases: remix-run/react-router
v4.0.0-alpha.4
Changes
- PropTypes are now exported (@alisd23 in #3910)
- Subscribe to location changes along context. Fixes usage with React Redux (@ryanflorence in bb7d8ee and ce59676)
- Strip propTypes in production (@mjackson in eb8a4ef)
- Remove the entire website application from the npm package (@timdorr in a5e05f7)
- StaticRouter now tracks location in state (@mjackson in 5550cc3)
- Rename PropTypes.router to PropTypes.routerContext (@mjackson in c8510da)
- Remove direct history dependency (@mjackson in a603eaa)
v4.0.0-alpha.3
Quick Version Note
I've swapped out the version string to better represent the prerelease nature of the v4
branch currently. It may not have been obvious before, but according to semver, any version string with a -anything
on the end is considered a prerelease version. I've seen some references to the versions before as 4.0.1 and 4.0.2. This isn't correct, as we haven't yet pushed a 4.0.0 final version. This is not production-ready code. We're not done building 4.0!
And, most importantly, we need your help to figure out things that are missing, either stuff that should go into the core of React Router or external libraries and code patterns that need to be established. React Router is now a building block as much as React itself is, and this more lean, mean, super-minimal core means that you can build a lot of interesting stuff on top of it. Now's a great time to get into open source and contribute some code. Keep those issues and PRs coming!
Also, for the love of god, yes, we know the docs site isn't scrollable. We'll push a new version soon!
Use this link for the docs site from now on: https://react-router.now.sh/ We'll keep it updated.
Changes
v3.0.0-beta.1
Installation
npm install react-router@beta
Changes
Sep 16, 2016
- Feature: Add Promise support to async route functions (#3719)
Upstream changes from v2.7.0 through v2.8.1:
- Bugfix: Fix redirects that specify
query
(#3808) - Feature: Support omitting
to
on<Link>
(#3803) - Refactor: Use
history.replace
instead ofhistory.transitionTo
for redirects (#3799) - Feature: Support
router
as a prop onwithRouter
-wrapped components for overriding the router object from context (#3729) - Feature: Add
withRef
option towithRouter
that enablesgetWrappedInstance
(#3735, #3740) - Bugfix: Warn on invalid router middlewares (#3717)
v4.0.0-2
v4.0.0-1
v4.0.0-0
⚠️ 🚀 NEW VERSION ALERT ⚠️
Available on npm: npm install react-router@next
This is a ground-up rewrite of React Router that @ryanflorence and @mjackson have been working on for the last few months (with a tiny bit of help from yours truly). The central thesis for this version is "declarative everything". Almost all imperative code is completely gone in 4.0.
The API is not only completely different, so is the way of thinking about routing in general. Async behaviors are gone, replaced by always rendering something (even if that's just a "Loading..." screen). There are no top-level route configuration, as you can "route" from anywhere in your component tree (but that doesn't keep you from creating your own route config).
We are working on an migration strategy that will allow you to run both version in tandem and update your routes incrementally.
Many of these familiar concepts are removed because they are best implemented from outside the router. v4 is much smaller in scope and code size, which is intentional. These, now external, features will eventually be implement as addon libraries, either provided officially or from the community.
As expected, there will be growing pains. And bugs. And Twitter flame wars 💦🔥. But this is a declarative, composable approach to routing that fits the declarative, composable model of React. Please let us know where it is not 100% awesome with issues and pull requests.
Quick Update:
Yes, there will still be a 3.0 release (soon!). It is simply v2.0 without any deprecation warnings. We intend to keep supporting the 3.x branch indefinitely (published separately on npm to aid in migration), although there will likely not be any future major versions based on that code. 4.0 is the future, but we won't leave you hanging if you want to stick with 2.x/3.x.