@opennextjs/aws 3.10.2 → 3.10.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -22,7 +22,6 @@ export function compileCache(options, format = "cjs") {
22
22
  js: [
23
23
  `globalThis.disableIncrementalCache = ${config.dangerous?.disableIncrementalCache ?? false};`,
24
24
  `globalThis.disableDynamoDBCache = ${config.dangerous?.disableTagCache ?? false};`,
25
- `globalThis.nextVersion = "${options.nextVersion}";`,
26
25
  ].join(""),
27
26
  },
28
27
  }, options);
@@ -40,7 +39,6 @@ export function compileCache(options, format = "cjs") {
40
39
  js: [
41
40
  `globalThis.disableIncrementalCache = ${config.dangerous?.disableIncrementalCache ?? false};`,
42
41
  `globalThis.disableDynamoDBCache = ${config.dangerous?.disableTagCache ?? false};`,
43
- `globalThis.nextVersion = "${options.nextVersion}";`,
44
42
  ].join(""),
45
43
  },
46
44
  }, options);
@@ -80,7 +80,7 @@ function findNextPackageJsonPath(appPath, root) {
80
80
  : path.join(root, "./package.json");
81
81
  }
82
82
  export function esbuildSync(esbuildOptions, options) {
83
- const { openNextVersion, debug, minify } = options;
83
+ const { openNextVersion, debug, minify, nextVersion } = options;
84
84
  const result = buildSync({
85
85
  target: "esnext",
86
86
  format: "esm",
@@ -98,6 +98,7 @@ export function esbuildSync(esbuildOptions, options) {
98
98
  esbuildOptions.banner?.js || "",
99
99
  `globalThis.openNextDebug = ${debug};`,
100
100
  `globalThis.openNextVersion = "${openNextVersion}";`,
101
+ `globalThis.nextVersion = "${nextVersion}";`,
101
102
  ].join(""),
102
103
  },
103
104
  });
@@ -107,7 +108,7 @@ export function esbuildSync(esbuildOptions, options) {
107
108
  }
108
109
  }
109
110
  export async function esbuildAsync(esbuildOptions, options) {
110
- const { openNextVersion, debug, minify } = options;
111
+ const { openNextVersion, debug, minify, nextVersion } = options;
111
112
  // Dump ESBuild build metadata to file in debug mode
112
113
  const metafile = debug && esbuildOptions.outfile !== undefined;
113
114
  const result = await buildAsync({
@@ -132,6 +133,7 @@ export async function esbuildAsync(esbuildOptions, options) {
132
133
  esbuildOptions.banner?.js || "",
133
134
  `globalThis.openNextDebug = ${debug};`,
134
135
  `globalThis.openNextVersion = "${openNextVersion}";`,
136
+ `globalThis.nextVersion = "${nextVersion}";`,
135
137
  ].join(""),
136
138
  },
137
139
  });
@@ -90,12 +90,6 @@ declare global {
90
90
  * Defined in esbuild banner for the cache adapter.
91
91
  */
92
92
  var disableIncrementalCache: boolean;
93
- /**
94
- * The Next.js version of the application.
95
- * Only available in the cache adapter.
96
- * Defined in the esbuild banner for the cache adapter.
97
- */
98
- var nextVersion: string;
99
93
  /**
100
94
  * A boolean that indicates if the runtime is Edge.
101
95
  * Only available in `edge` runtime functions (i.e. external middleware or function with edge runtime).
@@ -167,11 +161,12 @@ declare global {
167
161
  */
168
162
  var AsyncLocalStorage: any;
169
163
  /**
170
- * The version of the Open Next runtime.
164
+ * The versions of Open Next and Next.js.
171
165
  * Available everywhere.
172
166
  * Defined in the esbuild banner.
173
167
  */
174
168
  var openNextVersion: string;
169
+ var nextVersion: string;
175
170
  /**
176
171
  * The function that is used when resolving external rewrite requests.
177
172
  * Only available in main functions
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "access": "public"
4
4
  },
5
5
  "name": "@opennextjs/aws",
6
- "version": "3.10.2",
6
+ "version": "3.10.3",
7
7
  "bin": {
8
8
  "open-next": "./dist/index.js"
9
9
  },
@@ -60,7 +60,7 @@
60
60
  "typescript": "5.9.3"
61
61
  },
62
62
  "peerDependencies": {
63
- "next": ">=15.5.15 || >=16.2.3"
63
+ "next": ">=15.5.15 <16 || >=16.2.3"
64
64
  },
65
65
  "bugs": {
66
66
  "url": "https://github.com/opennextjs/opennextjs-aws/issues"