Re:Alpine.js Magic Helpers Library
by earthboundkid on Saturday February 13, 2021 @11:29PM
(#26129691)
I’ve been using it for projects where a non-JS backend mostly handles templates, but I still want modern JS framework-like interactivity. A nice thing compared to Vue and React is that Alpine takes its template from your HTML, not your JS, so all your JS needs to have is the controller data logic, and the actual template stuff can be with your non-JS template code.
[ Parent
| on HN ]
Re:Alpine.js Magic Helpers Library
by ficklepickle on Sunday February 14, 2021 @01:55PM
(#26135008)
Clearly you have never used Vue, because it works in the exact same way.
Alpine looks like Vue without computed properties.
Re:Alpine.js Magic Helpers Library
by earthboundkid on Sunday February 14, 2021 @03:04PM
(#26135730)
I have used Vue. In Vue, the templates are compiled and included if you use SFC, which is the preferred method. If you don’t use SFC, you have to ship the Vue compiler to your clients and that is not small. It’s a tradeoff.
Alpine doesn’t have a VDOM, so there’s no compiler and no equivalent of SFCs.