3 ms·
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
by earthboundkid 6y ago
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.
- ficklepickle 6y agoClearly you have never used Vue, because it works in the exact same way. Alpine looks like Vue without computed properties.
- earthboundkid 6y agoI 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.