Spyke

Syndicated from the fediverse. Read and engage on the original instance.

View original on lemmy.blackeco.com

2 replies

When used properly like the websocket example it's clear what it does. If you're using useEffect to sync props and state, then yes, you're going to have trouble reasoning through it. The solution is to not use useEffect because you're no longer writing React, you're writing Angular. No named function expression will fix that.

1

You reached the end

Start naming your useEffect functions, you will thank me later | Spyke