1. 程式人生 > >Did your deps make upgrading to React 16.x hard too?

Did your deps make upgrading to React 16.x hard too?

I am struggling not to spout cliches about how the JS community make breaking changes constantly.

Up to now I was one of the proponents of how great the ecosystem is (these days). I have been deeply frustrated by the number of libraries that made major breaking changes across different React versions, without a straightforward upgrade path, so instead of being able to incrementally upgrade I've been forced to bulk upgrade and fire-fight and read all the documentation in one mega upgrade...

React itself has a really good deprecation / upgrade version support, but I inherited a codebase using react-router (complete paradigm shift across versions), redux, redux-saga and a bunch of other deps with code splitting and webpack too, and this has been painful unlike any other upgrade I've had to do too.

The hot reloading library was deprecated, there were changes in the history api, the router is no longer parsing query strings and also changing the signature of the properties routes create have changed... I could go on and on, there was even a breaking API change to react-select!

My point is not that breaking changes are a problem on their own, it's that I was left with the version change dilemma where breaking changes across 10s of deps were made without a straightforward deprecation / migration path in a single version of React and I ended up with little choice but to upgrade everything and work through all the issues, until the thing built correctly again...

Anyone else have a similar experience?