@netlify/plugin-nextjs 4.17.1-runtime.7 → 4.19.0
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.
package/lib/helpers/utils.js
CHANGED
|
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.getCustomImageResponseHeaders = exports.isNextAuthInstalled = exports.findModuleFromBase = exports.shouldSkip = exports.getPreviewRewrites = exports.getApiRewrites = exports.redirectsForNextRouteWithData = exports.redirectsForNextRoute = exports.isApiRoute = exports.routeToDataRoute = exports.netlifyRoutesForNextRouteWithData = exports.toNetlifyRoute = void 0;
|
|
6
|
+
exports.isBundleSizeCheckDisabled = exports.getCustomImageResponseHeaders = exports.isNextAuthInstalled = exports.findModuleFromBase = exports.shouldSkip = exports.getPreviewRewrites = exports.getApiRewrites = exports.redirectsForNextRouteWithData = exports.redirectsForNextRoute = exports.isApiRoute = exports.routeToDataRoute = exports.netlifyRoutesForNextRouteWithData = exports.toNetlifyRoute = void 0;
|
|
7
7
|
const globby_1 = __importDefault(require("globby"));
|
|
8
8
|
const pathe_1 = require("pathe");
|
|
9
9
|
const constants_1 = require("../constants");
|
|
@@ -154,4 +154,6 @@ const getCustomImageResponseHeaders = (headers) => {
|
|
|
154
154
|
return null;
|
|
155
155
|
};
|
|
156
156
|
exports.getCustomImageResponseHeaders = getCustomImageResponseHeaders;
|
|
157
|
+
const isBundleSizeCheckDisabled = () => process.env.DISABLE_BUNDLE_ZIP_SIZE_CHECK === '1' || process.env.DISABLE_BUNDLE_ZIP_SIZE_CHECK === 'true';
|
|
158
|
+
exports.isBundleSizeCheckDisabled = isBundleSizeCheckDisabled;
|
|
157
159
|
/* eslint-enable max-lines */
|
|
@@ -36,6 +36,7 @@ const outdent_1 = require("outdent");
|
|
|
36
36
|
const pretty_bytes_1 = __importDefault(require("pretty-bytes"));
|
|
37
37
|
const semver_1 = require("semver");
|
|
38
38
|
const constants_1 = require("../constants");
|
|
39
|
+
const utils_1 = require("./utils");
|
|
39
40
|
// This is when nft support was added
|
|
40
41
|
const REQUIRED_BUILD_VERSION = '>=18.16.0';
|
|
41
42
|
const verifyNetlifyBuildVersion = ({ IS_LOCAL, NETLIFY_BUILD_VERSION, failBuild, }) => {
|
|
@@ -103,6 +104,12 @@ const checkForRootPublish = ({ publish, failBuild, }) => {
|
|
|
103
104
|
};
|
|
104
105
|
exports.checkForRootPublish = checkForRootPublish;
|
|
105
106
|
const checkZipSize = async (file, maxSize = constants_1.LAMBDA_MAX_SIZE) => {
|
|
107
|
+
// Requires contacting the Netlify Support team to fully enable.
|
|
108
|
+
// Enabling this without contacting them can result in failed deploys.
|
|
109
|
+
if ((0, utils_1.isBundleSizeCheckDisabled)()) {
|
|
110
|
+
console.warn('Function bundle size check was DISABLED with the DISABLE_BUNDLE_ZIP_SIZE_CHECK environment variable. Your deployment will break if it exceeds the maximum supported size of function zip files in your account.');
|
|
111
|
+
return;
|
|
112
|
+
}
|
|
106
113
|
if (!(0, fs_1.existsSync)(file)) {
|
|
107
114
|
console.warn(`Could not check zip size because ${file} does not exist`);
|
|
108
115
|
return;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@netlify/plugin-nextjs",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.19.0",
|
|
4
4
|
"description": "Run Next.js seamlessly on Netlify",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"files": [
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@netlify/esbuild": "0.14.25",
|
|
13
13
|
"@netlify/functions": "^1.2.0",
|
|
14
|
-
"@netlify/ipx": "^1.2.
|
|
14
|
+
"@netlify/ipx": "^1.2.3",
|
|
15
15
|
"@vercel/node-bridge": "^2.1.0",
|
|
16
16
|
"chalk": "^4.1.2",
|
|
17
17
|
"execa": "^5.1.1",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
32
|
"@delucis/if-env": "^1.1.2",
|
|
33
|
-
"@netlify/build": "^27.15.
|
|
33
|
+
"@netlify/build": "^27.15.7",
|
|
34
34
|
"@types/fs-extra": "^9.0.13",
|
|
35
35
|
"@types/jest": "^27.4.1",
|
|
36
36
|
"@types/node": "^17.0.25",
|