next 16.0.0-canary.5 → 16.0.0-canary.6
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/dist/bin/next +1 -1
- package/dist/build/index.js +4 -4
- package/dist/build/index.js.map +1 -1
- package/dist/build/swc/generated-native.d.ts +6 -6
- package/dist/build/swc/index.js +1 -1
- package/dist/build/templates/app-page.js +5 -6
- package/dist/build/templates/app-page.js.map +1 -1
- package/dist/build/webpack-config-rules/resolve.d.ts +1 -1
- package/dist/build/webpack-config-rules/resolve.js +8 -9
- package/dist/build/webpack-config-rules/resolve.js.map +1 -1
- package/dist/build/webpack-config.js +23 -16
- package/dist/build/webpack-config.js.map +1 -1
- package/dist/client/app-bootstrap.js +1 -1
- package/dist/client/index.js +1 -1
- package/dist/esm/build/index.js +4 -4
- package/dist/esm/build/index.js.map +1 -1
- package/dist/esm/build/swc/generated-native.d.ts +6 -6
- package/dist/esm/build/swc/index.js +1 -1
- package/dist/esm/build/templates/app-page.js +5 -6
- package/dist/esm/build/templates/app-page.js.map +1 -1
- package/dist/esm/build/webpack-config-rules/resolve.js +5 -7
- package/dist/esm/build/webpack-config-rules/resolve.js.map +1 -1
- package/dist/esm/build/webpack-config.js +24 -17
- package/dist/esm/build/webpack-config.js.map +1 -1
- package/dist/esm/client/app-bootstrap.js +1 -1
- package/dist/esm/client/index.js +1 -1
- package/dist/esm/server/config-schema.js +0 -1
- package/dist/esm/server/config-schema.js.map +1 -1
- package/dist/esm/server/config-shared.js +0 -1
- package/dist/esm/server/config-shared.js.map +1 -1
- package/dist/esm/server/config.js +5 -29
- package/dist/esm/server/config.js.map +1 -1
- package/dist/esm/server/dev/hot-reloader-turbopack.js +1 -1
- package/dist/esm/server/dev/hot-reloader-webpack.js +1 -1
- package/dist/esm/server/lib/app-info-log.js +1 -1
- package/dist/esm/server/lib/start-server.js +1 -1
- package/dist/esm/shared/lib/errors/canary-only-config-error.js +1 -1
- package/dist/server/config-schema.d.ts +0 -1
- package/dist/server/config-schema.js +0 -1
- package/dist/server/config-schema.js.map +1 -1
- package/dist/server/config-shared.d.ts +0 -7
- package/dist/server/config-shared.js +0 -1
- package/dist/server/config-shared.js.map +1 -1
- package/dist/server/config.js +5 -29
- package/dist/server/config.js.map +1 -1
- package/dist/server/dev/hot-reloader-turbopack.js +1 -1
- package/dist/server/dev/hot-reloader-webpack.js +1 -1
- package/dist/server/lib/app-info-log.js +1 -1
- package/dist/server/lib/start-server.js +1 -1
- package/dist/shared/lib/errors/canary-only-config-error.js +1 -1
- package/dist/telemetry/anonymous-meta.js +1 -1
- package/dist/telemetry/events/session-stopped.js +2 -2
- package/dist/telemetry/events/version.js +2 -2
- package/package.json +15 -15
|
@@ -139,8 +139,8 @@ function warnCustomizedOption(config, key, defaultValue, customMessage, configFi
|
|
|
139
139
|
* @param userConfig - The user config.
|
|
140
140
|
* @param silent - Whether to suppress warnings.
|
|
141
141
|
* @returns The complete config.
|
|
142
|
-
*/ function assignDefaultsAndValidate(dir, userConfig, silent,
|
|
143
|
-
var _result_experimental, _result_experimental1, _result_experimental_serverActions, _result_experimental2, _userConfig_experimental, _userConfig_experimental1, _userConfig_experimental2, _userConfig_experimental3, _userConfig_experimental4, _userConfig_experimental5, _userConfig_experimental6, _userConfig_experimental7, _userConfig_experimental8, _userConfig_experimental9, _userConfig_experimental10, _userConfig_experimental11, _result_experimental3, _result_turbopack, _result_turbopack1, _result_devIndicators, _result_experimental4, _result_experimental5,
|
|
142
|
+
*/ function assignDefaultsAndValidate(dir, userConfig, silent, phase) {
|
|
143
|
+
var _result_experimental, _result_experimental1, _result_experimental_serverActions, _result_experimental2, _userConfig_experimental, _userConfig_experimental1, _userConfig_experimental2, _userConfig_experimental3, _userConfig_experimental4, _userConfig_experimental5, _userConfig_experimental6, _userConfig_experimental7, _userConfig_experimental8, _userConfig_experimental9, _userConfig_experimental10, _userConfig_experimental11, _result_experimental3, _result_turbopack, _result_turbopack1, _result_devIndicators, _result_experimental4, _result_experimental5, _result_experimental6;
|
|
144
144
|
const configFileName = userConfig.configFileName;
|
|
145
145
|
if (typeof userConfig.exportTrailingSlash !== 'undefined') {
|
|
146
146
|
if (!silent) {
|
|
@@ -936,22 +936,6 @@ function warnCustomizedOption(config, key, defaultValue, customMessage, configFi
|
|
|
936
936
|
if (result.experimental.useCache === undefined) {
|
|
937
937
|
result.experimental.useCache = result.experimental.cacheComponents;
|
|
938
938
|
}
|
|
939
|
-
// If cacheComponents is enabled and the user hasn't configured
|
|
940
|
-
// rdcForNavigations, we enable it by default.
|
|
941
|
-
if (result.experimental.cacheComponents && ((_userConfig_experimental12 = userConfig.experimental) == null ? void 0 : _userConfig_experimental12.rdcForNavigations) === undefined) {
|
|
942
|
-
result.experimental.rdcForNavigations = true;
|
|
943
|
-
if (configuredExperimentalFeatures) {
|
|
944
|
-
addConfiguredExperimentalFeature(configuredExperimentalFeatures, 'rdcForNavigations', true, 'enabled by `experimental.cacheComponents`');
|
|
945
|
-
}
|
|
946
|
-
}
|
|
947
|
-
// If rdcForNavigations is enabled, but cacheComponents is not, we throw an error.
|
|
948
|
-
if (result.experimental.rdcForNavigations && !result.experimental.cacheComponents) {
|
|
949
|
-
throw Object.defineProperty(new Error('`experimental.rdcForNavigations` is enabled, but `experimental.cacheComponents` is not.'), "__NEXT_ERROR_CODE", {
|
|
950
|
-
value: "E865",
|
|
951
|
-
enumerable: false,
|
|
952
|
-
configurable: true
|
|
953
|
-
});
|
|
954
|
-
}
|
|
955
939
|
if (phase === PHASE_DEVELOPMENT_SERVER && ((_result_experimental6 = result.experimental) == null ? void 0 : _result_experimental6.isolatedDevBuild)) {
|
|
956
940
|
result.distDir = join(result.distDir, 'dev');
|
|
957
941
|
}
|
|
@@ -1051,7 +1035,7 @@ export default async function loadConfig(phase, dir, { customConfig, rawConfig,
|
|
|
1051
1035
|
configOrigin: 'server',
|
|
1052
1036
|
configFileName,
|
|
1053
1037
|
...customConfig
|
|
1054
|
-
}, silent,
|
|
1038
|
+
}, silent, phase), phase, silent);
|
|
1055
1039
|
// Cache the custom config result
|
|
1056
1040
|
configCache.set(cacheKey, {
|
|
1057
1041
|
config,
|
|
@@ -1175,7 +1159,7 @@ export default async function loadConfig(phase, dir, { customConfig, rawConfig,
|
|
|
1175
1159
|
configFile: path,
|
|
1176
1160
|
configFileName,
|
|
1177
1161
|
...userConfig
|
|
1178
|
-
}, silent,
|
|
1162
|
+
}, silent, phase);
|
|
1179
1163
|
const finalConfig = await applyModifyConfig(completeConfig, phase, silent);
|
|
1180
1164
|
// Cache the final result
|
|
1181
1165
|
configCache.set(cacheKey, {
|
|
@@ -1222,7 +1206,7 @@ export default async function loadConfig(phase, dir, { customConfig, rawConfig,
|
|
|
1222
1206
|
const completeConfig = assignDefaultsAndValidate(dir, {
|
|
1223
1207
|
...clonedDefaultConfig,
|
|
1224
1208
|
configFileName
|
|
1225
|
-
}, silent,
|
|
1209
|
+
}, silent, phase);
|
|
1226
1210
|
setHttpClientAndAgentOptions(completeConfig);
|
|
1227
1211
|
const finalConfig = await applyModifyConfig(completeConfig, phase, silent);
|
|
1228
1212
|
// Cache the default config result
|
|
@@ -1253,14 +1237,6 @@ function enforceExperimentalFeatures(config, options) {
|
|
|
1253
1237
|
addConfiguredExperimentalFeature(configuredExperimentalFeatures, 'cacheComponents', true, 'enabled by `__NEXT_EXPERIMENTAL_CACHE_COMPONENTS`');
|
|
1254
1238
|
}
|
|
1255
1239
|
}
|
|
1256
|
-
// TODO: Remove this once we've made RDC for Navigations the default for cache components.
|
|
1257
|
-
if (process.env.__NEXT_EXPERIMENTAL_CACHE_COMPONENTS === 'true' && // We do respect an explicit value in the user config.
|
|
1258
|
-
(config.experimental.rdcForNavigations === undefined || isDefaultConfig && !config.experimental.rdcForNavigations)) {
|
|
1259
|
-
config.experimental.rdcForNavigations = true;
|
|
1260
|
-
if (configuredExperimentalFeatures) {
|
|
1261
|
-
addConfiguredExperimentalFeature(configuredExperimentalFeatures, 'rdcForNavigations', true, 'enabled by `__NEXT_EXPERIMENTAL_CACHE_COMPONENTS`');
|
|
1262
|
-
}
|
|
1263
|
-
}
|
|
1264
1240
|
// TODO: Remove this once using the debug channel is the default.
|
|
1265
1241
|
if (process.env.__NEXT_EXPERIMENTAL_DEBUG_CHANNEL === 'true' && // We do respect an explicit value in the user config.
|
|
1266
1242
|
(config.experimental.reactDebugChannel === undefined || isDefaultConfig && !config.experimental.reactDebugChannel)) {
|