Skip to main content
Version: 0.1.x

FAQs

Components

Why not React/Vue/Angular/other application-focused frameworks?

The typical scenario for these frameworks involves them having full control over some part of the DOM. It's not practical to hand over the entire DOM to one of these frameworks (like you might do with an prerendered SPA which gets hydrated), as it wouldn't play nicely with external apps and Shopify features like Section Rendering. This is much more practical in the realm of headless Shopify.

Note that this doesn't mean that you can't use these frameworks with SALVO-TS - they aren't suitable as an overarching solution, but they are still usable for individual comonents. React and Vue are particularly well-suited for this, and SALVO-TS supports this natively for React - see React Components.

Why not LitElement/other WebComponent-focused frameworks?

Most WebComponent frameworks focus on "Complete" Web Components - that is, Web Components that use Shadow DOM and Scoped Styles. These are very cool technologies, but they fall foul of the same issues as the previous questions - Shadow DOMs can't be rendered in Liquid (and have some serious SEO concerns), and make it impractical to integrate external apps etc.

The Custom Elements part of the Web Components spec is what SALVO-TS uses, and it's a great solution to the requirements for loading and destroying components dynamically that Shopify and Online Store 2.0 presents. However, the rest of the Web Component spec just isn't practical in a primarly server-templated, server-rendered environment, and there aren't any well-established Web Component frameworks which seem to fit in this niche.