DEV Community

Discussion on: (An Approach to) Vue.js Template Variables

 
loilo profile image
Florian Reuschel

I think my perception of this as a "hack" mostly refers to "using assignment expressions as attributes". It just doesn't feel right (to me, personally). Sure, it's a thing we've done forever in on* event attributes, but at least the semantics of events do match this better than the semantics of vanilla attributes.

That's pretty much the same as let foo; while (foo = expression) { /* use foo */ } — it's a thing that is frowned upon by many readers and linters, but it's used because the clean way would be annoyingly verbose.

Thread Thread
 
pbastowski profile image
pbastowski

I hear you.