Live data from Hacker News

React v17.0 Release Candidate: No New Features

reactjs.org

21–30 of 120 posts

Re: React v17.0 Release Candidate: No New Features

#21
post #5
post #3

"It has been two and a half years since the previous major release of React, which is a long time even by our standards!" As a mostly Python and only occasional JavaScript developer, it always felt like the biggest challenge in the JavaScript community was how fast everything moved - new libraries, frameworks and ideas would tumble past at the rate of one every few weeks, and it felt impossible to keep up. I've been…

I second you on that. The number of times I've had to rewrite code because a framework decided to break everything with little warning.. I don't even want to think about it actually. I get wanting to make code better but gesh people, do some planning and figure out a direction to move a project. Also it seems JS devs don't understand semver either. Massive breaking changes in patch or minor versions are just evil.

Big name libraries and frameworks like React and Angular manage things relatively well and in a similar way to other frameworks in other languages (you could argue about AngularJS -> Angular but if you worked with both frameworks you know that AngularJS was a dead end approach designed for a completely different stack and it just didn't make sense to maintain backwards compatibility or maintaining that dumpster of a code base past it's EOL).

A problem in React ecosystem is that it's a rendering library not really a webapp framework so you need to use community provided libraries to fill in the gaps. Those libraries are often maintained by an individual so it's unreasonable to expect corporate SDK approach to development, but unfortunately it leads to a lot of abandonware and rewrites, especially since JS is not very maintainable and it's often easier to rewrite something than to pick up someone else's code.

Re: React v17.0 Release Candidate: No New Features

#22
post #7

React hooks is influenced by Dan, the author of Redux, not a fan of them both

I think React hooks are silly but Redux is an OK solution to a certain problem, and one of the nicer major libraries in all of JavaScript land, wildly better than almost anything else of similar prominence (it's fairly small and IIRC it has one dependency, with one other transitive dependency, and that's it). I don't see the philosophical or practical connection between the two.

`redux@^4` currently has two dependencies: `symbol-observable` for compat with observable libs, and `loose-envify` for compat with Browserify. I plan on removing both of those when we release Redux v5.

Our official Redux Toolkit package [0], which is now our recommended approach for writing Redux logic, _does_ have a few more deps: Immer, Reselect, Redux-Thunk, and the Redux core. But, those are all things you probably would have had in your app anyway.

If you're not familiar with Redux Toolkit, it includes utilities to simplify several common Redux use cases, including store setup, defining reducers, immutable update logic, and even creating entire "slices" of state at once.

I just published a brand-new "Redux Essentials" core docs tutorial [1], which teaches beginners "how to use Redux, the right way", using our latest recommended tools and practices. I'd encourage folks to check it out.

[0] https://redux-toolkit.js.org

[1] https://redux.js.org/tutorials/essentials/part-1-overview-co...

Re: React v17.0 Release Candidate: No New Features

#23
post #13
post #7

React hooks is influenced by Dan, the author of Redux, not a fan of them both

IMO Hooks is the best thing that happened to React. Once you get used to it it is a lot more clean and productive. It requires you to unlearn a few things though, e.g. don't think about component lifecycles, but think about data flow/changes. Once you get used to it is a lot more productive and enjoyable way of developing React apps.

I believe it would have been better to have Hooks as a separate library, not part of React. For the developer it is just another design pattern, not really an improvement, especially if you look at all the edge cases and issues you'll find around.

Personally I don't like the design pattern, a matter of taste. But it's very annoying now in the market to have mixed React and Hooks codebases, with all their issues..

Re: React v17.0 Release Candidate: No New Features

#24

Jet, Angular 9 has such slow build times I can even imagine anyone would use it: https://github.com/angular/angular/issues/37293 I have 2 comparable applications (in size) and React build times are 10 times faster than Angular.

It's sometimes easier and saner to develop a new component on something like stactblitz or a new angular project than make a change, wait 20s+ for compiler+browser to compiler and load code and view the new change. And repeat. And losing the hot-reloading with state b/c of the OOP heavy architecture in some shops, well that's not helping speed up write/reload/view change cycle at all.

And as you write larger and larger apps, with hundreds of components, it's just ridiculous how poorly the first-party tools handle that kind of code scale. Your only choice it to buy into Bazel to maintain some sense of sanity and productivity albeit some of which gets diminished with the overhead of learning, using and maintaining bazel for the project.

Complexity on top of complexity, nothing about Angular is simple.

Re: React v17.0 Release Candidate: No New Features

#25

Earlier quoted context omitted.

I think React hooks are silly but Redux is an OK solution to a certain problem, and one of the nicer major libraries in all of JavaScript land, wildly better than almost anything else of similar prominence (it's fairly small and IIRC it has one dependency, with one other transitive dependency, and that's it). I don't see the philosophical or practical connection between the two.

`redux@^4` currently has two dependencies: `symbol-observable` for compat with observable libs, and `loose-envify` for compat with Browserify. I plan on removing both of those when we release Redux v5. Our official Redux Toolkit package [0], which is now our recommended approach for writing Redux logic, _does_ have a few more deps: Immer, Reselect, Redux-Thunk, and the Redux core. But, those are all things you probab…

Thanks for your work on it. I've found Redux super-helpful and pleasant to use for multi-platform JS UI work, in particular, to bundle HTTP client (and other network services, if not in the browser) libs behind a common, small, well-understood-by-React-devs state interface. I'm a huge fan of dependencies I can abuse—fake-up in an afternoon on unsupported platforms in another language, rip out of one place and cram in another without a fuss, stuff like that. Redux is one of the rare deps in JavaScript I never feel queazy about including in a build.

I'm too out-of-the-loop these days to know what Immer is, will have to give it a look.

Re: React v17.0 Release Candidate: No New Features

#27
post #5
post #3

"It has been two and a half years since the previous major release of React, which is a long time even by our standards!" As a mostly Python and only occasional JavaScript developer, it always felt like the biggest challenge in the JavaScript community was how fast everything moved - new libraries, frameworks and ideas would tumble past at the rate of one every few weeks, and it felt impossible to keep up. I've been…

I second you on that. The number of times I've had to rewrite code because a framework decided to break everything with little warning.. I don't even want to think about it actually. I get wanting to make code better but gesh people, do some planning and figure out a direction to move a project. Also it seems JS devs don't understand semver either. Massive breaking changes in patch or minor versions are just evil.

React is actually pretty decent in terms of upgrading. Also, the idea of semver is more widespread in the JS community and there are things like Angular commits and tools like commitizen.

It has a tick-tock pattern so that you can upgrade and having time to fix the warnings.

The API changes are carefully crafted.

Sometimes there are even migration tools to help you upgrade.

Re: React v17.0 Release Candidate: No New Features

#28

Random thought after reading: I wish macOS / iOS / iPadOS would have a version without tons of new features.

Remember Snow Leopard? I miss that.

"Zero new features" was a nice marketing line for Snow Leopard. It did not reflect reality. Snow Leopard introduced Dock Exposé, Exchange support in Apple Mail, and Grand Central Dispatch. just to name three.

We've had similar releases since then which added a few new features but were primarily focused on stability. The most recent one was High Sierra. These do tend to be the best releases of macOS IMO.

Re: React v17.0 Release Candidate: No New Features

#29
post #3

"It has been two and a half years since the previous major release of React, which is a long time even by our standards!" As a mostly Python and only occasional JavaScript developer, it always felt like the biggest challenge in the JavaScript community was how fast everything moved - new libraries, frameworks and ideas would tumble past at the rate of one every few weeks, and it felt impossible to keep up. I've been…

React has actually been stable for much longer than that (say 5 years). There have technically been breaking changes, but in practice these required only minor code changes if any. They've introduced new coding styles (like hooks), but the olds ones still function just fine.

Re: React v17.0 Release Candidate: No New Features

#30
I've become increasingly disillusioned with the JS ecosystem over the past couple of years, but React still delivers. I can still chuck it in a script tag and start writing components if needed (without JSX). I haven't really used hooks yet and don't plan to, but as long as "legacy" class based components are supported, I will use them.

Thanks for maintaining backward compatibility, which is not very common in the JS world. And congrats on the release!

Post reply on HN