This project is a template for deploying applications using Honox on Cloudflare Pages. It leverages modern tools like Vite, Tailwind CSS, and Wrangler for a seamless development and deployment experience.
- Modern Development Stack: Utilizes Vite for fast builds and hot module replacement, Tailwind CSS for utility-first styling, and Wrangler for managing Cloudflare Workers.
- Seamless Deployment: Easily deploy applications to Cloudflare Pages with a single command.
- TypeScript Support: Full support for TypeScript, enabling type safety and better developer experience.
- Environment Management: Manage environment variables and secrets securely using Wrangler.
- Automated Testing: Includes a test suite powered by Vitest for ensuring code quality.
- Code Quality Tools: Integrated with Biome for code formatting and linting to maintain a clean codebase.
- End-to-End Testing: Includes Playwright for comprehensive end-to-end testing.
- Preview and Debugging: Preview applications locally and debug with Wrangler's preview feature.
- Extensible: Easily extendable with additional plugins and configurations to suit various project needs.
To get started with this project, clone the repository and install the dependencies:
git clone https://github.com/marco-souza/honox-cloudflare-template.git
cd honox-cloudflare-template
bun installTo start the development server, run:
bun run devThis will start a local development server with hot-reloading enabled.
To deploy the application to Cloudflare Pages, use:
bun run deploydev: Starts the Vite development server.tests: Runs the test suite using Vitest.build: Builds the application for production.e2e: Runs end-to-end tests using Playwright.fmt: Formats the code using Biome.lint: Lints the codebase and fixes issues.postinstall: Runs post-installation scripts.w: Alias for Wrangler commands.w:secret: Manages secrets for Cloudflare Pages.w:typegen: Generates types for Wrangler.preview: Previews the application using Wrangler.deploy: Builds and deploys the application.
Contributions are welcome! Please fork the repository and submit a pull request for any improvements or bug fixes.
This project is licensed under the MIT License.