Algebraic Effects for React Developers
I started learning React for starting a large project a few months ago. I have not really liked the experience very much. One seems to still need to know all the JS&#x2F;CSS&#x2F;HTML I&#x27;ve been using for 10+ years but also a new stack on top of it, simultaneously.<p>Hooks are one of the strangest features I&#x27;ve seen in a language yet. I doubt they will be a lasting paradigm outside of the React ecosystem.<p>I like JSX a lot. The idea of reusable stateless components is totally on the right track.<p>I&#x27;ve found React to be very hard to debug. I get stack traces that don&#x27;t seem to start from any code I&#x27;ve written.<p>I now somehow suspect that the next wave in the JS ecosystem will be doing something like microservices on the frontend - message passing between isolated webworkers? I ponder this because React has not, for me, achieved any level of enforcing a sane way of deciding which objects in memory belong to a given component. Something feels really wrong with the the React model of programming.<p>Writing a project in React seems doubly frustrating - there&#x27;s the challenge of a new stack and new programming model, but I don&#x27;t seem to be getting anything for the trade: the code isn&#x27;t easily debuggable, doesn&#x27;t have a great upgrade and maintainability story, the app still has race conditions, memory leaks, browser incompatibilities, tightly coupled components. The problem seems to be that React only gently encourages, but does not enforce, any good practices.