t3-code-android-nightly/.repos/alchemy-effect/examples/aws-website-foldkit
Julius Marminge e3c85ead63
chore(refs): sync Effect and Alchemy references to rc.115 and beta.78 (#12327)
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-09-17 23:21:25 -07:00
..
src chore(refs): sync Effect and Alchemy references to rc.115 and beta.78 (#12327) 2026-09-17 23:21:25 -07:00
test chore(refs): sync Effect and Alchemy references to rc.115 and beta.78 (#12327) 2026-09-17 23:21:25 -07:00
alchemy.run.ts chore(refs): sync Alchemy reference to beta.76 (#10654) 2026-09-07 21:54:45 -07:00
index.html chore(refs): sync Alchemy reference to beta.76 (#10654) 2026-09-07 21:54:45 -07:00
package.json chore(refs): sync Effect and Alchemy references to rc.115 and beta.78 (#12327) 2026-09-17 23:21:25 -07:00
README.md chore(refs): sync Alchemy reference to beta.76 (#10654) 2026-09-07 21:54:45 -07:00
tsconfig.json chore(refs): sync Alchemy reference to beta.76 (#10654) 2026-09-07 21:54:45 -07:00
vite.config.ts chore(refs): sync Alchemy reference to beta.76 (#10654) 2026-09-07 21:54:45 -07:00

AWS Website: Foldkit

Deploys a Foldkit app to AWS with AWS.Website.Foldkit — the client build in S3 behind a CloudFront distribution, no CloudFormation templates. Foldkit apps are client-only Vite projects, so the deployment is assets-only and never creates a server function.

  • src/main.ts holds the Elm-architecture model/update/view; the page renders a card view function (src/components/Card.ts) written in plain TypeScript with foldkit/html.
  • Tailwind CSS v4 is wired through @tailwindcss/vite in the project's own vite.config.ts, alongside @foldkit/vite-plugin.
  • Unmatched paths serve index.html (spa defaults on), so deep links boot the app and Foldkit routes on the client.

The integration package must be installed in the project (it is loaded dynamically at deploy time):

bun add -d @alchemy.run/frontend-frameworks

Deploy

bun install
bun run deploy

Unchanged sources skip the Vite build entirely on subsequent deploys — the input files are content-hashed (scoped by memo.include).

Local development

bun run dev

alchemy dev runs Vite's own dev server — Foldkit's HMR and devtools wiring work unchanged — and no AWS resources are created.

Destroy

bun run destroy