| 1 | import * as Alchemy from "alchemy"; |
| 2 | import * as Fly from "alchemy/Fly"; |
| 3 | import * as Effect from "effect/Effect"; |
| 4 | |
| 5 | export default Alchemy.Stack( |
| 6 | "FlyWebsiteSolidStartExample", |
| 7 | { |
| 8 | providers: Fly.providers(), |
| 9 | state: Alchemy.localState(), |
| 10 | }, |
| 11 | Effect.gen(function* () { |
| 12 | const site = yield* Fly.Website.SolidStart("Website", { |
| 13 | // Only hash the files that affect the build, so unchanged sources |
| 14 | // skip the SolidStart build (and the deploy) entirely. |
| 15 | memo: { |
| 16 | include: ["src/**", "public/**", "package.json", "vite.config.ts"], |
| 17 | }, |
| 18 | env: { |
| 19 | GREETING: "Hello from SolidStart on Fly!", |
| 20 | }, |
| 21 | }); |
| 22 | |
| 23 | return { |
| 24 | url: site.url, |
| 25 | }; |
| 26 | }), |
| 27 | ); |