๐—ฅ๐—ฒ๐—ฎ๐—ฐ๐˜ ๐Ÿญ๐Ÿต: ๐—ช๐—ต๐—ฒ๐—ป ๐˜๐—ผ ๐˜‚๐˜€๐—ฒ ๐˜‚๐˜€๐—ฒ() ๐˜ƒ๐˜€ ๐˜‚๐˜€๐—ฒ๐—˜๐—ณ๐—ณ๐—ฒ๐—ฐ๐˜

I replaced 3 useEffects with use() in React 19. I had to undo one. Here is what I learned.

use() reads a promise in a component. The component waits for the value. React handles the rest.

It works for these cases:

It removes useState and useEffect. It removes loading checks.

It fails for these cases:

The rule is simple. use() is for promises with one resolution. It does not handle cancellation.

Use useEffect for lifecycle work. Use TanStack Query for network calls.

New tools have narrow uses. Do not refactor everything. Test one example first.

Source: https://dev.to/sensational5510/i-rewrote-3-useeffects-to-use-in-react-19-heres-the-one-i-shouldnt-have-9db