Appearance
Glossary
The coined vocabulary, in one place. Each term links to the chapter that goes deep.
- Tenant — one merchant/store, represented as data keyed by a
tenant_id, not a deployment. → Multi-tenancy forTenant(id)— the one gate to tenant data; deny-by-default (a query without atenantIdthrows). → Architecture- Deny-by-default — access is refused unless explicitly granted (no membership row → no access). → Control plane & AI
base ⊕ overrides— a theme = an immutable versioned base library theme + a small bundle of only the files the merchant changed. → Rendering & themes- Bundle — a theme packed as one gzip blob, content-addressed by the SHA-256 of its files. → Theme pipeline
- The two render paths — the bundle theme path (primary, Liquid) and the legacy page-builder /
PageDocpath (JSON, fallback). → Rendering & themes PageDoc— the legacy page-builder's JSON document (thepagestable'sdraft_doc/live_doc). → Rendering & themes- Section / block — a section is a unit of a page (Liquid or first-party); a block is a repeatable item inside a section (
section.blocks). → Render internals - Chrome — the header/footer, rendered as their own templates (
header-group/footer-group). → Render internals - Isolate — two meanings. (a) a worker-thread isolate: the Node worker that runs untrusted merchant Liquid with a wall-clock kill; (b) a Workers/V8 isolate: the edge Worker's per-request runtime (the circuit breaker is "per-isolate"). Same word, different things. → Render engine & isolate / Edge internals
- Engine (the two copies) — the in-process LiquidJS engine (
engine.ts) and its hand-copied twin (worker.mjs) for the isolate; they must stay byte-identical. → Render engine & isolate - Resolver (
BindingResolver) — turns a page's declareddataSourcesinto products/collections/menus at render. → Commerce data & resolver - Provider seam — the per-store, per-capability pick of cart/login/checkout/account/search provider (GoKwik or native). → Commerce
- Island — the only per-user path: a cached shell carries an inert placeholder, hydrated client-side from
/api/island/*(no-store). → Rendering & themes - Surrogate keys / tags (a.k.a. cache tags) — the tags stamped on a cached page (
tenant,page,prod:*,col:*,menu:*) that a change purges by. → Commerce data & resolver x-edge-auth— the shared secret the edge sends so the private origin knows the request came from the edge. → Edge internalsx-ratio-tenant— the trusted header the edge injects to tell the origin which tenant (the origin trusts only this, never theHost). → Multi-tenancyx-ratio-stale— set on a response the edge served stale (origin was down/slow). → Edge internals- Fail-loud — on a broken render the origin returns a 500 (so the edge serves last-good) rather than a partial or silently-cached page. → Rendering & themes
- Paise — Indian currency minor unit (₹1 = 100 paise). The backend returns integer paise; the
moneyfilter divides by 100 at render. → Commerce data & resolver - CAS — compare-and-swap; the optimistic-concurrency check on a draft save (a
revisiontoken; a mismatch → 409). → Theme pipeline - SWR —
stale-while-revalidate, the Cache-Control directive letting the edge serve a stale copy while it revalidates. → Edge internals - DV — Domain Validation; the TXT-record check Cloudflare for SaaS runs before issuing a custom-domain TLS cert. → Infrastructure
- PDP / PLP — product-detail page (
/products/:handle) / product-listing (collection) page. → Multi-tenancy - IDOR — Insecure Direct Object Reference; accessing another user's object by id. (The account order fetch avoids it — GoKwik scopes it to the token's customer.) → Commerce internals
- JWE — JSON Web Encryption; the opaque KwikPass session token whose presence signals login (its contents are unreadable to us). → Commerce internals
_library— the system tenant that owns the shared base themes. → Data model- Composition root — the only place
process.envis read (apps/*/src/config.ts); packages take config injected. → Architecture