upvote
It is slightly different. Classes ended up being worse than what they were trying to supplement. Templating, if done right at least (a big if, granted), can bring small improvement. If classes were better, we wouldn't see them the same way now.
reply
How classes could be better? I don't think it's missing something that would make me use it
reply
I’m curious. What is actually wrong with querySelector?
reply
String interpolation is so ridiculously slow. Epic slow.

Perhaps just as importantly is that is a crutch for many to avoid accessing the DOM in steps. You can read from the DOM with querySelectors but you cannot modify the DOM with them. If querySelectors is all you can do then you must use some third party template system because you have no idea how any of this works even though it provides maximal expressive freedom.

reply
Is anything preventing JS from compiling the proper stepwise dom access if the querySelector parameter is a literal? That would basically push the interpolation into the parsing step.
reply