Skip to main content

Liquid Build And Publish

Liquid publish is source-package based. Shoppex validates and renders the source package directly.

High-Level Flow

1

Upload source

CLI, dashboard, MCP, or Dev API sends the Liquid source package.
2

Validate package

Shoppex validates theme-package.json, declared files, safe Liquid usage, safe markup, and package limits.
3

Build CSS assets

assets/built.css is produced from CSS that scans .liquid sources.
4

Store immutable artifact

Public assets are versioned with the artifact. Render-only Liquid source is stored privately and linked to the same immutable publish.
5

Render with Shoppex

Live cache misses render through the Shoppex Liquid renderer.
6

Serve at the edge

Shoppex handles domain routing, cache lookup/write, purge, and versioned asset serving.

Source vs Artifact

There are two important objects:
ObjectPurpose
Liquid source packageEditable runtime source: layout, sections, snippets, settings, schema, and manifest
Published artifactImmutable live version: public assets plus private render source reference
There is no second compiled template artifact as the live contract. .liquid source files remain the render source of truth.

What Publish Requires

Publish requires:
  • valid theme-package.json
  • all declared layout, section, snippet, settings, schema, and asset files present
  • assets/built.css
  • no undeclared templates
  • no dynamic partials
  • no unsafe markup or executable source files
  • successful server-side validation
Simple example: if theme-package.json declares sections/hero.liquid but the file is missing, publish fails. Shoppex does not infer a replacement.

Preview vs Publish

Preview and live rendering use the same Liquid core.
OperationEffect
shoppex theme validateChecks the draft package
shoppex theme previewStarts a sandboxed storefront render for review
shoppex theme publishBuilds and activates a live immutable artifact
shoppex theme publish --build-onlyBuilds an artifact without making it active

Runtime Manifest

Published Liquid artifacts declare render.mode = server-liquid. If a new publish does not have a valid Liquid package, the pipeline fails fast.

Checks

shoppex theme validate --include-typecheck
shoppex theme preview

Next Steps

Serving & Caching

How Shoppex serves HTML and assets.

Troubleshooting

Fix validation, preview, and publish issues.