Что-то про React – Telegram
Что-то про React
300 subscribers
3 photos
498 links
Немного про React.
Список статей и новостей подбирается полностью вручную.
Download Telegram
Rename Priority Levels

The Core team also made small changes to some of the API names for the scheduler - one of the building blocks of React’s upcoming concurrent mode. The API is not final and we can expect an RFC soon.

https://github.com/facebook/react/pull/13842
🕵️‍♀️ Deprecate findDOMNode in StrictMode

In an attempt to make React applications easier to maintain, the Core team considers deprecating findDOMNode. The current API is breaking abstraction levels which leads to refactoring hazard.

https://github.com/facebook/react/pull/13841
Revert: React.pure() Automatically Forwards Ref

Last week we were covering a PR that added forwardRef behavior to React.pure() by default. The PR was since reverted while the Core team is working on the future of ref forwarding.

https://github.com/facebook/react/pull/13887
🔥 RFC: React Hooks

The React team announced Hooks - A new and backwards-compatible Component API. In addition to the RFC, the team also launched [a complete set of documentation](https://reactjs.org/docs/hooks-intro.html). You can play around with React Hooks today by using the v16.7.0-alpha release on npm.

https://github.com/reactjs/rfcs/pull/68
🎉 React v16.6.0: lazy, memo and contextType

This week also marks the release of the stable v16.6. This not only adds the lazy, memo, contextType, and getDerivedStateFromError APIs that we covered in previous issues, but is also the first public build where Suspense is no longer behind a feature flag and not marked unstable.

https://reactjs.org/blog/2018/10/23/react-v-16-6.html
➡️ React.pure() is now React.memo()

After discussions in the RFC that we covered last week, React.pure() is now called React.memo().

https://github.com/facebook/react/pull/13905
📚 Remove cache as argument to read in React Cache

The React Cache API is still unstable and will undergo more changes. The cache is now read from context and cache invalidation was removed entirely. You can try it out in the v2.0.0-alpha.0 release.

https://github.com/facebook/react/pull/13865
🔁 Add Back Proper AsyncMode Symbol for Back Compat

Thanks to Jordan Harband (ljharb), the react-is package to test arbitrary values and see if they’re a particular React element type now correctly handles the meanwhile renamed AsyncMode component.
https://github.com/facebook/react/pull/13959
⁉️ Don’t Lint Against Hooks After Conditional Throw

To make working with React Hooks easier, the Core team is working on a linter rule that helps to comply with the Rules of Hooks. This PR takes the custom linter one step forward.
https://github.com/facebook/react/pull/14040
🧠 A Metaphor for Concurrent React

Dan wrote an excellent metaphor for the upcoming concurrent mode in React. Check out his Twitter thread if you’re curious about the mental model behind this upcoming feature.

https://twitter.com/dan_abramov/status/1059059596835340288
Add a Low Priority to the Scheduler

Nathan Schloss (n8schloss) made a PR to add another priority level to the experimental Scheduler package. This new priority will still resolve but only after everything else. This is useful for logging or sending data back to the server.

https://github.com/facebook/react/pull/14155