Hacker News new | ask | show | jobs
by brundolf 1798 days ago
You're right that this doesn't represent the way a vanilla JS UI would ever actually be written in practice (even calling it a "vanilla JS UI" instead of an "html UI" points directly at the problem)

But:

1) Even though the web-specific example is contrived, it's a good demonstration/explanation of what people mean generally by declarative vs imperative

2) I don't want to wade into the tired argument, but classic HTML + minimal hand-written JS doesn't scale beyond a certain point. If it did, everyone would still be doing things that way