Platforms
Alchemy and Cloudflare
A guide to setting up a Cloudflare Workers development environment with Alchemy.
Prepare the example
Install the current Node.js LTS and Vite+.
vp create effront -- my-app --platform alchemy-cloudflare
cd my-app
vp installFind the application and resource definitions
The one-page example already contains the host configuration:
| File | Role |
|---|---|
src/entry.effront.tsx | Defines the document layout, one page, and its / route. |
src/entry.workers.ts | Declares the Worker and defers loading the application until a request. |
alchemy.run.ts | Defines the Stack and outputs the Worker's URL. |
vite.config.ts | Registers effront() and effrontAlchemy(). |
package.json | Defines dev as alchemy dev. |
Start development
From the generated project, run:
vp run devWhen ready, open the local URL printed by Alchemy. The single page displays Hello, world.
Change <h1>Hello, world</h1> in src/entry.effront.tsx to <h1>Hello, Effront!</h1> and save.
Add resources when needed
For application services using resources such as KV and D1, follow Alchemy Basic, Alchemy's resource APIs, and the Effront Alchemy API reference.