Foldkit
Source:
src/Railway/Website/Foldkit.ts
Deploy a Foldkit app to Railway: a Vite SPA with
unmatched paths falling back to index.html so deep links boot the
Foldkit router. Same Node static-file Service as Vite.
Foldkit apps are client-only Vite projects — the Foldkit Vite plugin in
the app’s vite.config.ts composes with the project’s own Vite build.
During alchemy dev the site is Vite’s own dev server and no cloud
resources are created. Alchemy.remote() opts back into the live
Service path.
Deploying a Foldkit App
Section titled “Deploying a Foldkit App”Foldkit app
const site = yield* Railway.Website.Foldkit("Website");Foldkit project in a subdirectory
const site = yield* Railway.Website.Foldkit("Website", { rootDir: "applications/web",});Single-Page Application Routing
Section titled “Single-Page Application Routing”const site = yield* Railway.Website.Foldkit("Website", { assets: { notFoundHandling: "404-page" },});