Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/opennextjs/opennextjs-cloudflare
Open Next.js adapter for Cloudflare
https://github.com/opennextjs/opennextjs-cloudflare
cloudflare nextjs react workers
Last synced: 5 days ago
JSON representation
Open Next.js adapter for Cloudflare
- Host: GitHub
- URL: https://github.com/opennextjs/opennextjs-cloudflare
- Owner: opennextjs
- License: mit
- Created: 2024-09-12T10:17:50.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2024-12-19T18:03:46.000Z (5 days ago)
- Last Synced: 2024-12-19T19:19:48.132Z (5 days ago)
- Topics: cloudflare, nextjs, react, workers
- Language: TypeScript
- Homepage: https://opennext.js.org/cloudflare
- Size: 1.27 MB
- Stars: 446
- Watchers: 10
- Forks: 17
- Open Issues: 56
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# Deploy Next.js apps to Cloudflare
[OpenNext for Cloudflare](https://opennext.js.org/cloudflare) is an adapter that enables the deployment of Next.js applications to Cloudflare's developer platform.
This monorepo includes a package for adapting a Next.js application built via `next build` (in standalone mode) to run in the Cloudflare workerd runtime using the [Workers Node.js compatibility layer](https://developers.cloudflare.com/workers/runtime-apis/nodejs/).
## Get started
Visit the [OpenNext docs](https://opennext.js.org/cloudflare/get-started) for instructions on starting a new project, or migrating an existing one.
## Contributing
### The repository
The repository contains two directories:
- `packages` containing a cloudflare package that can be used to build a Cloudflare Workers-compatible output for Next.js applications.
- `examples` containing Next.js applications that use the above mentioned cloudflare package.### How to try out the `@opennextjs/cloudflare` package
You can simply install the package from npm as specified in the [OpenNext documentation](https://opennext.js.org/cloudflare/get-started).
#### Preleases
Besides the standard npm releases we also automatically publish prerelease packages on branch pushes (using [`pkg.pr.new`](https://github.com/stackblitz-labs/pkg.pr.new)):
- `https://pkg.pr.new/@opennextjs/cloudflare@main`:
Updated with every push to the `main` branch, this prerelease contains the most up to date yet (reasonably) stable version of the package.
- `https://pkg.pr.new/@opennextjs/cloudflare@experimental`
Updated with every push to the `experimental` branch, this prerelease contains the latest experimental version of the package (containing features that we want to test/experiment on before committing to).Which you can simply install directly with your package manager of choice, for example:
```bash
npm i https://pkg.pr.new/@opennextjs/cloudflare@main
```### How to develop in the repository
See the [CONTRIBUTING](./CONTRIBUTING.md) page for how to get started with this repository.