Skip to content

Commit

Permalink
fix middleware for next 15 (#473)
Browse files Browse the repository at this point in the history
* fix middleware for next 15 latest canary

* Create angry-fans-kick.md
  • Loading branch information
conico974 authored Jul 20, 2024
1 parent 220be99 commit 75857cf
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .changeset/angry-fans-kick.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"open-next": patch
---

fix middleware for next 15
8 changes: 8 additions & 0 deletions packages/open-next/src/build/edge/createEdgeBundle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,14 @@ export async function buildEdgeBundle({
const require = (await import("node:module")).createRequire(import.meta.url);
const __filename = (await import("node:url")).fileURLToPath(import.meta.url);
const __dirname = (await import("node:path")).dirname(__filename);
const defaultDefineProperty = Object.defineProperty;
Object.defineProperty = function(o, p, a) {
if(p=== '__import_unsupported') {
return;
}
return defaultDefineProperty(o, p, a);
};
`
}
${additionalInject ?? ""}
Expand Down

0 comments on commit 75857cf

Please sign in to comment.