index.liquid file, in Shopify-style syntax. No JavaScript needed.
Real example: Noir in
templates/themes/noir/.The folder
Steps
1
Write theme.json
theme.json
2
Write index.html
The same file as in React. It must load
/src/platform/entry.tsx.3
Add a section
schema.json is the same as in React. The design:src/sections/cta-banner/index.liquid
4
Zip, upload, publish
See Upload rules.
Objects
Filters
All standard Liquid filters work too:
upcase, default, size, date and the rest.
Tags
Output is escaped by default, so text from settings is safe.
Add a script
Put anindex.ts next to index.liquid, exporting mount(el, ctx). It runs after every render. Use it for sliders or menus.
Cart and checkout
No API calls needed. Adddata-jm-* attributes, or call window.JoinMarkt:
Events on
document: jm:cart when the cart changes, jm:checkout-error when checkout can’t start. All attributes: Commerce attributes.
Next
Upload rules
What gets kept, and every error.
Commerce attributes
Add to cart from plain markup.

