Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/ninety-plums-roll.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@opennextjs/cloudflare": minor
---

Introduce two new entry points to the @opennextjs/cloudflare package, `/cli` and `/lib`. `/cli` is intended to be an entry point for developers looking to use the CLI programmatically, which is a use case especially relevant for using @opennextjs/cloudflare with Workers for Platforms. The new `/lib` entry point is a duplicate of the existing catch-all (`/*`) entry point, but can be used in the future to more explicitly differentiate between exports intended for a Next.js app being deployed to Cloudflare, vs. exports related to programmatic usage of the CLI.
10 changes: 10 additions & 0 deletions packages/cloudflare/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,16 @@
"import": "./dist/api/*.js",
"types": "./dist/api/*.d.ts",
"default": "./dist/api/*.js"
},
"./lib/*": {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know I suggested lib but by looking at the PR it looks to me like we might as well stick with api since that's already used 🙂

"import": "./dist/api/*.js",
"types": "./dist/api/*.d.ts",
"default": "./dist/api/*.js"
},
"./cli/*": {
"import": "./dist/cli/*.js",
"types": "./dist/cli/*.d.ts",
"default": "./dist/cli/*.js"
}
},
"files": [
Expand Down