3 ms·
I'm proficient with React hooks and functional components, but I will never bullshit anyone by pretending that they make any kind of intuitive sense. Classes m
by prohobo 5y ago
I'm proficient with React hooks and functional components, but I will never bullshit anyone by pretending that they make any kind of intuitive sense.
Classes may have been more "code" but were clear to understand. I don't dispute that functional components are probably more efficient though.
Anyways, I've never had this problem with React hooks. I've been building complex dynamic UIs for years, and maybe I've grown to get around these kinds of things, but it seems like Solid.js is solving a niche problem at the cost of making hooks even less understandable?
- imtringued 5y agoThey literally don't. For some reason the developers think that storing state in hidden global variables (linked list indexed by hook call order) is a good idea. You know, they could have at least defined useReducer inside the class. Of course that would sort of break the pretentious ability to define hooks as global functions that access component state. After all, you would have to pass the current component as the first parameter, imagine the horror!