News for hackers. Stuff that matters.
Re:Alpine.js: A minimal framework for composing JavaScript b... by codedokode on Monday February 10, 2020 @10:05AM (#22289674)
What an awful idea:

- first, it is not obvious whether an attribute affects something or not. How are you supposed to know what this or that attribute does?

- second, if you made a typo, there is no error messages

- third, no there is no namespaces and attributes can conflict with attributes from other libraries

What's wrong with good old inline event handlers like onclick? With them you can just click a called function name and see its source.

Re:Alpine.js: A minimal framework for composing JavaScript b... by whoisjuan on Monday February 10, 2020 @12:26PM (#22291149)
> What's wrong with good old inline event handlers like onclick? With them you can just click a called function name and see its source.

I haven't read the source of Alpine but I'm assuming the inline declarations are abstractions that are moved out of the DOM execution context and therefore can be cached. Real inline event handlers will actually be evaluated and executed in every page load, which will affect performance, especially with inside loops.