The best way to control Claude Code, Codex and more from any computer or phone

main
ts 33 lines 827 Bytes
Raw
1 import * as Railway from "@alchemy.run/railway";
2 import * as Alchemy from "alchemy";
3 import * as Effect from "effect/Effect";
4
5 export default Alchemy.Stack(
6 "RailwayWebsiteReactRouterExample",
7 {
8 providers: Railway.providers(),
9 state: Alchemy.localState(),
10 },
11 Effect.gen(function* () {
12 const site = yield* Railway.Website.ReactRouter("Website", {
13 // Only hash the files that affect the build, so unchanged sources
14 // skip the React Router build (and the deploy) entirely.
15 memo: {
16 include: [
17 "app/**",
18 "public/**",
19 "package.json",
20 "react-router.config.ts",
21 "vite.config.ts",
22 ],
23 },
24 env: {
25 GREETING: "Hello from React Router on Railway!",
26 },
27 });
28
29 return {
30 url: site.url,
31 };
32 }),
33 );