The demo (demo.pcbjam.com) cross-posts the waitlist to the marketing site's
serverless endpoint. It targeted the apex pcbjam.com, which 308-redirects to
www on Vercel; a CORS preflight can't follow redirects, so the OPTIONS failed
("Redirect is not allowed for a preflight request") and the POST never landed.
Point the waitlist target at the canonical www host. www.pcbjam.com already
returns 204 with access-control-allow-origin: https://demo.pcbjam.com, so the
preflight passes. Landing/version-badge link stays on the apex.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01REwWZGkAz1AZUJw8yqxkCN
59 lines
3.2 KiB
Shell
59 lines
3.2 KiB
Shell
# Standalone editor (Vite). Copy to standalone/.env. All vars must be VITE_-prefixed.
|
|
|
|
# Backend implementing the @pcbjam/shared contract (the example backend, or any
|
|
# conforming backend). Leave it pointing anywhere unreachable to use only the
|
|
# local-folder loader on the home page.
|
|
VITE_API_BASE_URL=http://localhost:3060
|
|
|
|
# Where PROJECTS come from: "remote" (default — the @pcbjam/shared backend above)
|
|
# or "static" (a read-only example gallery served from a CDN, NO backend — the
|
|
# demo.pcbjam.com mode; editor saves download to local). For "static" you must
|
|
# also set VITE_PROJECT_MANIFEST_URL.
|
|
# VITE_PROJECT_SOURCE=static
|
|
# VITE_PROJECT_MANIFEST_URL=https://cdn.pcbjam.com/content/2.7.7/manifest.json
|
|
|
|
# WASM asset root (no trailing slash). On `dev` the artifacts are symlinked into
|
|
# public/wasm and served by Vite at /wasm (a FLAT layout — files live directly
|
|
# under the root). For a prod CDN set an absolute URL, e.g.:
|
|
# VITE_WASM_ROOT=https://cdn.pcbjam.com/wasm
|
|
# A cross-origin CDN works: boot.ts loads the pthread worker via a same-origin
|
|
# blob shim, and the CDN must send CORP: cross-origin + ACAO (+ COEP/COOP on the
|
|
# app). VITE_WASM_ASSET_BASE_URL is the legacy name and is still honored.
|
|
VITE_WASM_ROOT=/wasm
|
|
|
|
# Per-release WASM manifest file under VITE_WASM_ROOT (e.g. "manifest-2.7.7.json").
|
|
# When set, the editor resolves each tool's versioned, content-addressed folder
|
|
# (VITE_WASM_ROOT/<tool>/<ver>/) from it at runtime (see docs/features/demo-deploy).
|
|
# Leave UNSET for the flat dev layout above.
|
|
# VITE_WASM_MANIFEST=manifest-2.7.7.json
|
|
|
|
# Override the artifact source dir the dev symlink points at (default:
|
|
# <repo>/tests/apps/kicad). Useful when serving prebuilt artifacts from elsewhere.
|
|
# WASM_SRC_DIR=
|
|
|
|
# Marketing / landing page the version badge links to (default https://pcbjam.com).
|
|
# VITE_LANDING_URL=https://pcbjam.com
|
|
|
|
# Where the in-editor waitlist form POSTs (default https://www.pcbjam.com/api/waitlist).
|
|
# The demo is static with no backend, so it cross-posts to the landing site's
|
|
# serverless endpoint, which must send CORS for this origin (see
|
|
# site/src/pages/api/waitlist.ts). Same JSON contract {email, source, company_url}.
|
|
# Use the canonical www host: the apex 308-redirects to www and a CORS preflight
|
|
# can't follow redirects.
|
|
# VITE_WAITLIST_URL=https://www.pcbjam.com/api/waitlist
|
|
|
|
# Plausible analytics. Unset ⇒ no tracking (dev/checkout default). Set the
|
|
# data-domain to enable; override the script URL only if the default plausible.io
|
|
# script won't load under COEP require-corp (then self-host/proxy on cdn.pcbjam.com).
|
|
# VITE_PLAUSIBLE_DOMAIN=demo.pcbjam.com
|
|
# VITE_PLAUSIBLE_SRC=https://plausible.io/js/script.js
|
|
|
|
# Where a backend project's DOCUMENT content lives ("api" default | "ydoc").
|
|
# Same /p/<project> URLs either way. "api": file bytes come from the REST
|
|
# backend and a user save (File->Save in the editor) is uploaded back to it.
|
|
# "ydoc": the collab room (VITE_YJS_PROVIDER) is the source of truth - when the
|
|
# room holds the document it is materialized client-side instead of fetched,
|
|
# and saves stay in the browser (the provider persists the doc); the REST
|
|
# backend still serves project metadata + sibling files, and the file fetch is
|
|
# the first-open fallback that seeds the room.
|
|
# VITE_DOC_SOURCE=ydoc
|