3 ms·
I easily see the superiority. The data controls the UI, instead of some random line of code that's very hard to find. Essentially it's declarative programming
by bufferoverflow 4y ago
I easily see the superiority. The data controls the UI, instead of some random line of code that's very hard to find.
Essentially it's declarative programming, you declare your UI should look this way when the state is this, and that way when the state is that.
It's much easier to reason about than when you have a thousand random functions that can change the UI, often in ways that break each other.
- tambourine_man 4y agoThat’s what I meant by team dynamics. I can separate concerns instead of multiple functions changing the same UI, but I can’t guarantee that everyone else will. The conventions that React provides sidesteps the need for discipline and that I find useful. Doesn’t mean that the approach in itself is better, IMO. and if you work alone, it’s clearly way too much trouble for little gain.