@openuiai/next 15.6.0-bun.15 → 15.6.0-bun.16
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 +3 -3
- package/dist/build/swc/index.js +1 -1
- package/dist/build/webpack-build/impl.d.ts +1 -0
- package/dist/build/webpack-build/impl.js +1 -0
- package/dist/build/webpack-build/impl.js.map +1 -1
- package/dist/build/webpack-config.js +2 -2
- package/dist/client/app-bootstrap.js +1 -1
- package/dist/client/index.js +1 -1
- package/dist/compiled/next-server/pages-api.runtime.dev.js +1 -1
- package/dist/compiled/next-server/pages-api.runtime.dev.js.map +1 -1
- package/dist/compiled/next-server/pages.runtime.dev.js +1 -1
- package/dist/compiled/next-server/pages.runtime.dev.js.map +1 -1
- package/dist/esm/build/index.js +3 -3
- package/dist/esm/build/swc/index.js +1 -1
- package/dist/esm/build/webpack-build/impl.js +1 -0
- package/dist/esm/build/webpack-build/impl.js.map +1 -1
- package/dist/esm/build/webpack-config.js +2 -2
- package/dist/esm/client/app-bootstrap.js +1 -1
- package/dist/esm/client/index.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/canary-only.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/canary-only.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 +1 -1
package/dist/esm/build/index.js
CHANGED
|
@@ -301,7 +301,7 @@ export default async function build(dir, reactProductionProfiling = false, debug
|
|
|
301
301
|
const nextBuildSpan = trace('next-build', undefined, {
|
|
302
302
|
buildMode: experimentalBuildMode,
|
|
303
303
|
isTurboBuild: String(isTurbopack),
|
|
304
|
-
version: "15.6.0-bun.
|
|
304
|
+
version: "15.6.0-bun.16"
|
|
305
305
|
});
|
|
306
306
|
NextBuildContext.nextBuildSpan = nextBuildSpan;
|
|
307
307
|
NextBuildContext.dir = dir;
|
|
@@ -780,7 +780,7 @@ export default async function build(dir, reactProductionProfiling = false, debug
|
|
|
780
780
|
// Files outside of the distDir can be "type": "module"
|
|
781
781
|
await writeFileUtf8(path.join(distDir, 'package.json'), '{"type": "commonjs"}');
|
|
782
782
|
// These are written to distDir, so they need to come after creating and cleaning distDr.
|
|
783
|
-
await recordFrameworkVersion("15.6.0-bun.
|
|
783
|
+
await recordFrameworkVersion("15.6.0-bun.16");
|
|
784
784
|
await updateBuildDiagnostics({
|
|
785
785
|
buildStage: 'start'
|
|
786
786
|
});
|
|
@@ -2425,7 +2425,7 @@ export default async function build(dir, reactProductionProfiling = false, debug
|
|
|
2425
2425
|
distDir,
|
|
2426
2426
|
config,
|
|
2427
2427
|
staticPages,
|
|
2428
|
-
nextVersion: "15.6.0-bun.
|
|
2428
|
+
nextVersion: "15.6.0-bun.16",
|
|
2429
2429
|
tracingRoot: outputFileTracingRoot,
|
|
2430
2430
|
hasNodeMiddleware,
|
|
2431
2431
|
hasInstrumentationHook,
|
|
@@ -11,7 +11,7 @@ import { isDeepStrictEqual } from 'util';
|
|
|
11
11
|
import { getDefineEnv } from '../define-env';
|
|
12
12
|
import { getReactCompilerLoader } from '../get-babel-loader-config';
|
|
13
13
|
import { throwTurbopackInternalError } from '../../shared/lib/turbopack/internal-error';
|
|
14
|
-
const nextVersion = "15.6.0-bun.
|
|
14
|
+
const nextVersion = "15.6.0-bun.16";
|
|
15
15
|
const ArchName = arch();
|
|
16
16
|
const PlatformName = platform();
|
|
17
17
|
function infoLog(...args) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/build/webpack-build/impl.ts"],"sourcesContent":["import type { webpack } from 'next/dist/compiled/webpack/webpack'\nimport { stringBufferUtils } from 'next/dist/compiled/webpack-sources3'\nimport { red } from '../../lib/picocolors'\nimport formatWebpackMessages from '../../shared/lib/format-webpack-messages'\nimport { nonNullable } from '../../lib/non-nullable'\nimport type { COMPILER_INDEXES } from '../../shared/lib/constants'\nimport {\n COMPILER_NAMES,\n CLIENT_STATIC_FILES_RUNTIME_MAIN_APP,\n APP_CLIENT_INTERNALS,\n PHASE_PRODUCTION_BUILD,\n} from '../../shared/lib/constants'\nimport { runCompiler } from '../compiler'\nimport * as Log from '../output/log'\nimport getBaseWebpackConfig, { loadProjectInfo } from '../webpack-config'\nimport type { NextError } from '../../lib/is-error'\nimport {\n TelemetryPlugin,\n type TelemetryPluginState,\n} from '../webpack/plugins/telemetry-plugin/telemetry-plugin'\nimport {\n NextBuildContext,\n resumePluginState,\n getPluginState,\n} from '../build-context'\nimport { createEntrypoints } from '../entries'\nimport loadConfig from '../../server/config'\nimport {\n getTraceEvents,\n initializeTraceState,\n setGlobal,\n trace,\n type TraceEvent,\n type TraceState,\n} from '../../trace'\nimport { WEBPACK_LAYERS } from '../../lib/constants'\nimport { TraceEntryPointsPlugin } from '../webpack/plugins/next-trace-entrypoints-plugin'\nimport type { BuildTraceContext } from '../webpack/plugins/next-trace-entrypoints-plugin'\nimport type { UnwrapPromise } from '../../lib/coalesced-function'\n\nimport origDebug from 'next/dist/compiled/debug'\nimport { Telemetry } from '../../telemetry/storage'\nimport { durationToString } from '../duration-to-string'\n\nconst debug = origDebug('next:build:webpack-build')\n\nfunction hrtimeToSeconds(hrtime: [number, number]): number {\n // hrtime is a tuple of [seconds, nanoseconds]\n return hrtime[0] + hrtime[1] / 1e9\n}\n\ntype CompilerResult = {\n errors: webpack.StatsError[]\n warnings: webpack.StatsError[]\n stats: (webpack.Stats | undefined)[]\n}\n\ntype SingleCompilerResult = {\n errors: webpack.StatsError[]\n warnings: webpack.StatsError[]\n stats: webpack.Stats | undefined\n}\n\nfunction isTelemetryPlugin(plugin: unknown): plugin is TelemetryPlugin {\n return plugin instanceof TelemetryPlugin\n}\n\nfunction isTraceEntryPointsPlugin(\n plugin: unknown\n): plugin is TraceEntryPointsPlugin {\n return plugin instanceof TraceEntryPointsPlugin\n}\n\nexport async function webpackBuildImpl(\n compilerName: keyof typeof COMPILER_INDEXES | null\n): Promise<{\n duration: number\n pluginState: any\n buildTraceContext?: BuildTraceContext\n telemetryState?: TelemetryPluginState\n}> {\n let result: CompilerResult | null = {\n warnings: [],\n errors: [],\n stats: [],\n }\n let webpackBuildStart\n const nextBuildSpan = NextBuildContext.nextBuildSpan!\n const dir = NextBuildContext.dir!\n const config = NextBuildContext.config!\n process.env.NEXT_COMPILER_NAME = compilerName || 'server'\n\n const runWebpackSpan = nextBuildSpan.traceChild('run-webpack-compiler')\n const entrypoints = await nextBuildSpan\n .traceChild('create-entrypoints')\n .traceAsyncFn(() =>\n createEntrypoints({\n buildId: NextBuildContext.buildId!,\n config: config,\n envFiles: NextBuildContext.loadedEnvFiles!,\n isDev: false,\n rootDir: dir,\n pageExtensions: config.pageExtensions!,\n pagesDir: NextBuildContext.pagesDir!,\n appDir: NextBuildContext.appDir!,\n pages: NextBuildContext.mappedPages!,\n appPaths: NextBuildContext.mappedAppPages!,\n previewMode: NextBuildContext.previewProps!,\n rootPaths: NextBuildContext.mappedRootPaths!,\n hasInstrumentationHook: NextBuildContext.hasInstrumentationHook!,\n })\n )\n\n const commonWebpackOptions = {\n isServer: false,\n isCompileMode: NextBuildContext.isCompileMode,\n buildId: NextBuildContext.buildId!,\n encryptionKey: NextBuildContext.encryptionKey!,\n config: config,\n appDir: NextBuildContext.appDir!,\n pagesDir: NextBuildContext.pagesDir!,\n rewrites: NextBuildContext.rewrites!,\n originalRewrites: NextBuildContext.originalRewrites,\n originalRedirects: NextBuildContext.originalRedirects,\n reactProductionProfiling: NextBuildContext.reactProductionProfiling!,\n noMangling: NextBuildContext.noMangling!,\n clientRouterFilters: NextBuildContext.clientRouterFilters!,\n previewProps: NextBuildContext.previewProps!,\n allowedRevalidateHeaderKeys: NextBuildContext.allowedRevalidateHeaderKeys!,\n fetchCacheKeyPrefix: NextBuildContext.fetchCacheKeyPrefix!,\n }\n\n const configs = await runWebpackSpan\n .traceChild('generate-webpack-config')\n .traceAsyncFn(async () => {\n const info = await loadProjectInfo({\n dir,\n config: commonWebpackOptions.config,\n dev: false,\n })\n return Promise.all([\n getBaseWebpackConfig(dir, {\n ...commonWebpackOptions,\n middlewareMatchers: entrypoints.middlewareMatchers,\n runWebpackSpan,\n compilerType: COMPILER_NAMES.client,\n entrypoints: entrypoints.client,\n ...info,\n }),\n getBaseWebpackConfig(dir, {\n ...commonWebpackOptions,\n runWebpackSpan,\n middlewareMatchers: entrypoints.middlewareMatchers,\n compilerType: COMPILER_NAMES.server,\n entrypoints: entrypoints.server,\n ...info,\n }),\n getBaseWebpackConfig(dir, {\n ...commonWebpackOptions,\n runWebpackSpan,\n middlewareMatchers: entrypoints.middlewareMatchers,\n compilerType: COMPILER_NAMES.edgeServer,\n entrypoints: entrypoints.edgeServer,\n ...info,\n }),\n ])\n })\n\n const clientConfig = configs[0]\n const serverConfig = configs[1]\n const edgeConfig = configs[2]\n\n if (\n clientConfig.optimization &&\n (clientConfig.optimization.minimize !== true ||\n (clientConfig.optimization.minimizer &&\n clientConfig.optimization.minimizer.length === 0))\n ) {\n Log.warn(\n `Production code optimization has been disabled in your project. Read more: https://nextjs.org/docs/messages/minification-disabled`\n )\n }\n\n webpackBuildStart = process.hrtime()\n\n debug(`starting compiler`, compilerName)\n // We run client and server compilation separately to optimize for memory usage\n await runWebpackSpan.traceAsyncFn(async () => {\n if (config.experimental.webpackMemoryOptimizations) {\n stringBufferUtils.disableDualStringBufferCaching()\n stringBufferUtils.enterStringInterningRange()\n }\n\n // Run the server compilers first and then the client\n // compiler to track the boundary of server/client components.\n let clientResult: SingleCompilerResult | null = null\n\n // During the server compilations, entries of client components will be\n // injected to this set and then will be consumed by the client compiler.\n let serverResult: UnwrapPromise<ReturnType<typeof runCompiler>>[0] | null =\n null\n let edgeServerResult:\n | UnwrapPromise<ReturnType<typeof runCompiler>>[0]\n | null = null\n\n let inputFileSystem: webpack.Compiler['inputFileSystem'] | undefined\n\n if (!compilerName || compilerName === 'server') {\n debug('starting server compiler')\n const start = Date.now()\n ;[serverResult, inputFileSystem] = await runCompiler(serverConfig, {\n runWebpackSpan,\n inputFileSystem,\n })\n debug(`server compiler finished ${Date.now() - start}ms`)\n }\n\n if (!compilerName || compilerName === 'edge-server') {\n debug('starting edge-server compiler')\n const start = Date.now()\n ;[edgeServerResult, inputFileSystem] = edgeConfig\n ? await runCompiler(edgeConfig, { runWebpackSpan, inputFileSystem })\n : [null]\n debug(`edge-server compiler finished ${Date.now() - start}ms`)\n }\n\n // Only continue if there were no errors\n if (!serverResult?.errors.length && !edgeServerResult?.errors.length) {\n const pluginState = getPluginState()\n for (const key in pluginState.injectedClientEntries) {\n const value = pluginState.injectedClientEntries[key]\n const clientEntry = clientConfig.entry as webpack.EntryObject\n if (key === APP_CLIENT_INTERNALS) {\n clientEntry[CLIENT_STATIC_FILES_RUNTIME_MAIN_APP] = {\n import: [\n // TODO-APP: cast clientEntry[CLIENT_STATIC_FILES_RUNTIME_MAIN_APP] to type EntryDescription once it's available from webpack\n // @ts-expect-error clientEntry['main-app'] is type EntryDescription { import: ... }\n ...clientEntry[CLIENT_STATIC_FILES_RUNTIME_MAIN_APP].import,\n value,\n ],\n layer: WEBPACK_LAYERS.appPagesBrowser,\n }\n } else {\n clientEntry[key] = {\n dependOn: [CLIENT_STATIC_FILES_RUNTIME_MAIN_APP],\n import: value,\n layer: WEBPACK_LAYERS.appPagesBrowser,\n }\n }\n }\n\n if (!compilerName || compilerName === 'client') {\n debug('starting client compiler')\n const start = Date.now()\n ;[clientResult, inputFileSystem] = await runCompiler(clientConfig, {\n runWebpackSpan,\n inputFileSystem,\n })\n debug(`client compiler finished ${Date.now() - start}ms`)\n }\n }\n\n if (config.experimental.webpackMemoryOptimizations) {\n stringBufferUtils.exitStringInterningRange()\n }\n inputFileSystem?.purge?.()\n\n result = {\n warnings: [\n ...(clientResult?.warnings ?? []),\n ...(serverResult?.warnings ?? []),\n ...(edgeServerResult?.warnings ?? []),\n ].filter(nonNullable),\n errors: [\n ...(clientResult?.errors ?? []),\n ...(serverResult?.errors ?? []),\n ...(edgeServerResult?.errors ?? []),\n ].filter(nonNullable),\n stats: [\n clientResult?.stats,\n serverResult?.stats,\n edgeServerResult?.stats,\n ],\n }\n })\n result = nextBuildSpan\n .traceChild('format-webpack-messages')\n .traceFn(() => formatWebpackMessages(result, true)) as CompilerResult\n\n const telemetryPlugin = (clientConfig as webpack.Configuration).plugins?.find(\n isTelemetryPlugin\n )\n\n const traceEntryPointsPlugin = (\n serverConfig as webpack.Configuration\n ).plugins?.find(isTraceEntryPointsPlugin)\n\n const webpackBuildEnd = process.hrtime(webpackBuildStart)\n\n if (result.errors.length > 0) {\n // Only keep the first few errors. Others are often indicative\n // of the same problem, but confuse the reader with noise.\n if (result.errors.length > 5) {\n result.errors.length = 5\n }\n let error = result.errors.filter(Boolean).join('\\n\\n')\n\n console.error(red('Failed to compile.\\n'))\n\n if (\n error.indexOf('private-next-pages') > -1 &&\n error.indexOf('does not contain a default export') > -1\n ) {\n const page_name_regex = /'private-next-pages\\/(?<page_name>[^']*)'/\n const parsed = page_name_regex.exec(error)\n const page_name = parsed && parsed.groups && parsed.groups.page_name\n throw new Error(\n `webpack build failed: found page without a React Component as default export in pages/${page_name}\\n\\nSee https://nextjs.org/docs/messages/page-without-valid-component for more info.`\n )\n }\n\n console.error(error)\n console.error()\n\n if (\n error.indexOf('private-next-pages') > -1 ||\n error.indexOf('__next_polyfill__') > -1\n ) {\n const err = new Error(\n 'webpack config.resolve.alias was incorrectly overridden. https://nextjs.org/docs/messages/invalid-resolve-alias'\n ) as NextError\n err.code = 'INVALID_RESOLVE_ALIAS'\n throw err\n }\n const err = new Error(\n `Build failed because of ${process.env.NEXT_RSPACK ? 'Rspack' : 'webpack'} errors`\n ) as NextError\n err.code = 'WEBPACK_ERRORS'\n throw err\n } else {\n const duration = hrtimeToSeconds(webpackBuildEnd)\n const durationString = durationToString(duration)\n\n if (result.warnings.length > 0) {\n Log.warn(`Compiled with warnings in ${durationString}\\n`)\n console.warn(result.warnings.filter(Boolean).join('\\n\\n'))\n console.warn()\n } else if (!compilerName) {\n Log.event(`Compiled successfully in ${durationString}`)\n }\n\n return {\n duration,\n buildTraceContext: traceEntryPointsPlugin?.buildTraceContext,\n pluginState: getPluginState(),\n telemetryState: {\n usages: telemetryPlugin?.usages() || [],\n packagesUsedInServerSideProps:\n telemetryPlugin?.packagesUsedInServerSideProps() || [],\n useCacheTracker: telemetryPlugin?.getUseCacheTracker() || {},\n },\n }\n }\n}\n\n// the main function when this file is run as a worker\nexport async function workerMain(workerData: {\n compilerName: keyof typeof COMPILER_INDEXES\n buildContext: typeof NextBuildContext\n traceState: TraceState\n}): Promise<\n Awaited<ReturnType<typeof webpackBuildImpl>> & {\n debugTraceEvents: TraceEvent[]\n }\n> {\n // Clone the telemetry for worker\n const telemetry = new Telemetry({\n distDir: workerData.buildContext.config!.distDir,\n })\n setGlobal('telemetry', telemetry)\n // setup new build context from the serialized data passed from the parent\n Object.assign(NextBuildContext, workerData.buildContext)\n\n // Initialize tracer state from the parent\n initializeTraceState(workerData.traceState)\n\n // Resume plugin state\n resumePluginState(NextBuildContext.pluginState)\n\n /// load the config because it's not serializable\n NextBuildContext.config = await loadConfig(\n PHASE_PRODUCTION_BUILD,\n NextBuildContext.dir!,\n { debugPrerender: NextBuildContext.debugPrerender }\n )\n NextBuildContext.nextBuildSpan = trace(\n `worker-main-${workerData.compilerName}`\n )\n\n const result = await webpackBuildImpl(workerData.compilerName)\n const { entriesTrace, chunksTrace } = result.buildTraceContext ?? {}\n if (entriesTrace) {\n const { entryNameMap, depModArray } = entriesTrace\n if (depModArray) {\n result.buildTraceContext!.entriesTrace!.depModArray = depModArray\n }\n if (entryNameMap) {\n const entryEntries = entryNameMap\n result.buildTraceContext!.entriesTrace!.entryNameMap = entryEntries\n }\n }\n if (chunksTrace?.entryNameFilesMap) {\n const entryNameFilesMap = chunksTrace.entryNameFilesMap\n result.buildTraceContext!.chunksTrace!.entryNameFilesMap = entryNameFilesMap\n }\n NextBuildContext.nextBuildSpan.stop()\n return { ...result, debugTraceEvents: getTraceEvents() }\n}\n"],"names":["stringBufferUtils","red","formatWebpackMessages","nonNullable","COMPILER_NAMES","CLIENT_STATIC_FILES_RUNTIME_MAIN_APP","APP_CLIENT_INTERNALS","PHASE_PRODUCTION_BUILD","runCompiler","Log","getBaseWebpackConfig","loadProjectInfo","TelemetryPlugin","NextBuildContext","resumePluginState","getPluginState","createEntrypoints","loadConfig","getTraceEvents","initializeTraceState","setGlobal","trace","WEBPACK_LAYERS","TraceEntryPointsPlugin","origDebug","Telemetry","durationToString","debug","hrtimeToSeconds","hrtime","isTelemetryPlugin","plugin","isTraceEntryPointsPlugin","webpackBuildImpl","compilerName","result","warnings","errors","stats","webpackBuildStart","nextBuildSpan","dir","config","process","env","NEXT_COMPILER_NAME","runWebpackSpan","traceChild","entrypoints","traceAsyncFn","buildId","envFiles","loadedEnvFiles","isDev","rootDir","pageExtensions","pagesDir","appDir","pages","mappedPages","appPaths","mappedAppPages","previewMode","previewProps","rootPaths","mappedRootPaths","hasInstrumentationHook","commonWebpackOptions","isServer","isCompileMode","encryptionKey","rewrites","originalRewrites","originalRedirects","reactProductionProfiling","noMangling","clientRouterFilters","allowedRevalidateHeaderKeys","fetchCacheKeyPrefix","configs","info","dev","Promise","all","middlewareMatchers","compilerType","client","server","edgeServer","clientConfig","serverConfig","edgeConfig","optimization","minimize","minimizer","length","warn","inputFileSystem","experimental","webpackMemoryOptimizations","disableDualStringBufferCaching","enterStringInterningRange","clientResult","serverResult","edgeServerResult","start","Date","now","pluginState","key","injectedClientEntries","value","clientEntry","entry","import","layer","appPagesBrowser","dependOn","exitStringInterningRange","purge","filter","traceFn","telemetryPlugin","plugins","find","traceEntryPointsPlugin","webpackBuildEnd","error","Boolean","join","console","indexOf","page_name_regex","parsed","exec","page_name","groups","Error","err","code","NEXT_RSPACK","duration","durationString","event","buildTraceContext","telemetryState","usages","packagesUsedInServerSideProps","useCacheTracker","getUseCacheTracker","workerMain","workerData","telemetry","distDir","buildContext","Object","assign","traceState","debugPrerender","entriesTrace","chunksTrace","entryNameMap","depModArray","entryEntries","entryNameFilesMap","stop","debugTraceEvents"],"mappings":"AACA,SAASA,iBAAiB,QAAQ,sCAAqC;AACvE,SAASC,GAAG,QAAQ,uBAAsB;AAC1C,OAAOC,2BAA2B,2CAA0C;AAC5E,SAASC,WAAW,QAAQ,yBAAwB;AAEpD,SACEC,cAAc,EACdC,oCAAoC,EACpCC,oBAAoB,EACpBC,sBAAsB,QACjB,6BAA4B;AACnC,SAASC,WAAW,QAAQ,cAAa;AACzC,YAAYC,SAAS,gBAAe;AACpC,OAAOC,wBAAwBC,eAAe,QAAQ,oBAAmB;AAEzE,SACEC,eAAe,QAEV,uDAAsD;AAC7D,SACEC,gBAAgB,EAChBC,iBAAiB,EACjBC,cAAc,QACT,mBAAkB;AACzB,SAASC,iBAAiB,QAAQ,aAAY;AAC9C,OAAOC,gBAAgB,sBAAqB;AAC5C,SACEC,cAAc,EACdC,oBAAoB,EACpBC,SAAS,EACTC,KAAK,QAGA,cAAa;AACpB,SAASC,cAAc,QAAQ,sBAAqB;AACpD,SAASC,sBAAsB,QAAQ,mDAAkD;AAIzF,OAAOC,eAAe,2BAA0B;AAChD,SAASC,SAAS,QAAQ,0BAAyB;AACnD,SAASC,gBAAgB,QAAQ,wBAAuB;AAExD,MAAMC,QAAQH,UAAU;AAExB,SAASI,gBAAgBC,MAAwB;IAC/C,8CAA8C;IAC9C,OAAOA,MAAM,CAAC,EAAE,GAAGA,MAAM,CAAC,EAAE,GAAG;AACjC;AAcA,SAASC,kBAAkBC,MAAe;IACxC,OAAOA,kBAAkBnB;AAC3B;AAEA,SAASoB,yBACPD,MAAe;IAEf,OAAOA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BAAqBoI,WAAWM,UAAU;IAE1C,sBAAsB;IACtB/I,kBAAkBD,iBAAiB+F,WAAW;IAE9C,iDAAiD;IACjD/F,iBAAiB6B,MAAM,GAAG,MAAMzB,WAC9BV,wBACAM,iBAAiB4B,GAAG,EACpB;QAAEqH,gBAAgBjJ,iBAAiBiJ,cAAc;IAAC;IAEpDjJ,iBAAiB2B,aAAa,GAAGnB,MAC/B,CAAC,YAAY,EAAEkI,WAAWrH,YAAY,EAAE;IAG1C,MAAMC,SAAS,MAAMF,iBAAiBsH,WAAWrH,YAAY;IAC7D,MAAM,EAAE6H,YAAY,EAAEC,WAAW,EAAE,GAAG7H,OAAO6G,iBAAiB,IAAI,CAAC;IACnE,IAAIe,cAAc;QAChB,MAAM,EAAEE,YAAY,EAAEC,WAAW,EAAE,GAAGH;QACtC,IAAIG,aAAa;YACf/H,OAAO6G,iBAAiB,CAAEe,YAAY,CAAEG,WAAW,GAAGA;QACxD;QACA,IAAID,cAAc;YAChB,MAAME,eAAeF;YACrB9H,OAAO6G,iBAAiB,CAAEe,YAAY,CAAEE,YAAY,GAAGE;QACzD;IACF;IACA,IAAIH,+BAAAA,YAAaI,iBAAiB,EAAE;QAClC,MAAMA,oBAAoBJ,YAAYI,iBAAiB;QACvDjI,OAAO6G,iBAAiB,CAAEgB,WAAW,CAAEI,iBAAiB,GAAGA;IAC7D;IACAvJ,iBAAiB2B,aAAa,CAAC6H,IAAI;IACnC,OAAO;QAAE,GAAGlI,MAAM;QAAEmI,kBAAkBpJ;IAAiB;AACzD","ignoreList":[0]}
|
|
1
|
+
{"version":3,"sources":["../../../src/build/webpack-build/impl.ts"],"sourcesContent":["import '../../server/require-hook'\nimport type { webpack } from 'next/dist/compiled/webpack/webpack'\nimport { stringBufferUtils } from 'next/dist/compiled/webpack-sources3'\nimport { red } from '../../lib/picocolors'\nimport formatWebpackMessages from '../../shared/lib/format-webpack-messages'\nimport { nonNullable } from '../../lib/non-nullable'\nimport type { COMPILER_INDEXES } from '../../shared/lib/constants'\nimport {\n COMPILER_NAMES,\n CLIENT_STATIC_FILES_RUNTIME_MAIN_APP,\n APP_CLIENT_INTERNALS,\n PHASE_PRODUCTION_BUILD,\n} from '../../shared/lib/constants'\nimport { runCompiler } from '../compiler'\nimport * as Log from '../output/log'\nimport getBaseWebpackConfig, { loadProjectInfo } from '../webpack-config'\nimport type { NextError } from '../../lib/is-error'\nimport {\n TelemetryPlugin,\n type TelemetryPluginState,\n} from '../webpack/plugins/telemetry-plugin/telemetry-plugin'\nimport {\n NextBuildContext,\n resumePluginState,\n getPluginState,\n} from '../build-context'\nimport { createEntrypoints } from '../entries'\nimport loadConfig from '../../server/config'\nimport {\n getTraceEvents,\n initializeTraceState,\n setGlobal,\n trace,\n type TraceEvent,\n type TraceState,\n} from '../../trace'\nimport { WEBPACK_LAYERS } from '../../lib/constants'\nimport { TraceEntryPointsPlugin } from '../webpack/plugins/next-trace-entrypoints-plugin'\nimport type { BuildTraceContext } from '../webpack/plugins/next-trace-entrypoints-plugin'\nimport type { UnwrapPromise } from '../../lib/coalesced-function'\n\nimport origDebug from 'next/dist/compiled/debug'\nimport { Telemetry } from '../../telemetry/storage'\nimport { durationToString } from '../duration-to-string'\n\nconst debug = origDebug('next:build:webpack-build')\n\nfunction hrtimeToSeconds(hrtime: [number, number]): number {\n // hrtime is a tuple of [seconds, nanoseconds]\n return hrtime[0] + hrtime[1] / 1e9\n}\n\ntype CompilerResult = {\n errors: webpack.StatsError[]\n warnings: webpack.StatsError[]\n stats: (webpack.Stats | undefined)[]\n}\n\ntype SingleCompilerResult = {\n errors: webpack.StatsError[]\n warnings: webpack.StatsError[]\n stats: webpack.Stats | undefined\n}\n\nfunction isTelemetryPlugin(plugin: unknown): plugin is TelemetryPlugin {\n return plugin instanceof TelemetryPlugin\n}\n\nfunction isTraceEntryPointsPlugin(\n plugin: unknown\n): plugin is TraceEntryPointsPlugin {\n return plugin instanceof TraceEntryPointsPlugin\n}\n\nexport async function webpackBuildImpl(\n compilerName: keyof typeof COMPILER_INDEXES | null\n): Promise<{\n duration: number\n pluginState: any\n buildTraceContext?: BuildTraceContext\n telemetryState?: TelemetryPluginState\n}> {\n let result: CompilerResult | null = {\n warnings: [],\n errors: [],\n stats: [],\n }\n let webpackBuildStart\n const nextBuildSpan = NextBuildContext.nextBuildSpan!\n const dir = NextBuildContext.dir!\n const config = NextBuildContext.config!\n process.env.NEXT_COMPILER_NAME = compilerName || 'server'\n\n const runWebpackSpan = nextBuildSpan.traceChild('run-webpack-compiler')\n const entrypoints = await nextBuildSpan\n .traceChild('create-entrypoints')\n .traceAsyncFn(() =>\n createEntrypoints({\n buildId: NextBuildContext.buildId!,\n config: config,\n envFiles: NextBuildContext.loadedEnvFiles!,\n isDev: false,\n rootDir: dir,\n pageExtensions: config.pageExtensions!,\n pagesDir: NextBuildContext.pagesDir!,\n appDir: NextBuildContext.appDir!,\n pages: NextBuildContext.mappedPages!,\n appPaths: NextBuildContext.mappedAppPages!,\n previewMode: NextBuildContext.previewProps!,\n rootPaths: NextBuildContext.mappedRootPaths!,\n hasInstrumentationHook: NextBuildContext.hasInstrumentationHook!,\n })\n )\n\n const commonWebpackOptions = {\n isServer: false,\n isCompileMode: NextBuildContext.isCompileMode,\n buildId: NextBuildContext.buildId!,\n encryptionKey: NextBuildContext.encryptionKey!,\n config: config,\n appDir: NextBuildContext.appDir!,\n pagesDir: NextBuildContext.pagesDir!,\n rewrites: NextBuildContext.rewrites!,\n originalRewrites: NextBuildContext.originalRewrites,\n originalRedirects: NextBuildContext.originalRedirects,\n reactProductionProfiling: NextBuildContext.reactProductionProfiling!,\n noMangling: NextBuildContext.noMangling!,\n clientRouterFilters: NextBuildContext.clientRouterFilters!,\n previewProps: NextBuildContext.previewProps!,\n allowedRevalidateHeaderKeys: NextBuildContext.allowedRevalidateHeaderKeys!,\n fetchCacheKeyPrefix: NextBuildContext.fetchCacheKeyPrefix!,\n }\n\n const configs = await runWebpackSpan\n .traceChild('generate-webpack-config')\n .traceAsyncFn(async () => {\n const info = await loadProjectInfo({\n dir,\n config: commonWebpackOptions.config,\n dev: false,\n })\n return Promise.all([\n getBaseWebpackConfig(dir, {\n ...commonWebpackOptions,\n middlewareMatchers: entrypoints.middlewareMatchers,\n runWebpackSpan,\n compilerType: COMPILER_NAMES.client,\n entrypoints: entrypoints.client,\n ...info,\n }),\n getBaseWebpackConfig(dir, {\n ...commonWebpackOptions,\n runWebpackSpan,\n middlewareMatchers: entrypoints.middlewareMatchers,\n compilerType: COMPILER_NAMES.server,\n entrypoints: entrypoints.server,\n ...info,\n }),\n getBaseWebpackConfig(dir, {\n ...commonWebpackOptions,\n runWebpackSpan,\n middlewareMatchers: entrypoints.middlewareMatchers,\n compilerType: COMPILER_NAMES.edgeServer,\n entrypoints: entrypoints.edgeServer,\n ...info,\n }),\n ])\n })\n\n const clientConfig = configs[0]\n const serverConfig = configs[1]\n const edgeConfig = configs[2]\n\n if (\n clientConfig.optimization &&\n (clientConfig.optimization.minimize !== true ||\n (clientConfig.optimization.minimizer &&\n clientConfig.optimization.minimizer.length === 0))\n ) {\n Log.warn(\n `Production code optimization has been disabled in your project. Read more: https://nextjs.org/docs/messages/minification-disabled`\n )\n }\n\n webpackBuildStart = process.hrtime()\n\n debug(`starting compiler`, compilerName)\n // We run client and server compilation separately to optimize for memory usage\n await runWebpackSpan.traceAsyncFn(async () => {\n if (config.experimental.webpackMemoryOptimizations) {\n stringBufferUtils.disableDualStringBufferCaching()\n stringBufferUtils.enterStringInterningRange()\n }\n\n // Run the server compilers first and then the client\n // compiler to track the boundary of server/client components.\n let clientResult: SingleCompilerResult | null = null\n\n // During the server compilations, entries of client components will be\n // injected to this set and then will be consumed by the client compiler.\n let serverResult: UnwrapPromise<ReturnType<typeof runCompiler>>[0] | null =\n null\n let edgeServerResult:\n | UnwrapPromise<ReturnType<typeof runCompiler>>[0]\n | null = null\n\n let inputFileSystem: webpack.Compiler['inputFileSystem'] | undefined\n\n if (!compilerName || compilerName === 'server') {\n debug('starting server compiler')\n const start = Date.now()\n ;[serverResult, inputFileSystem] = await runCompiler(serverConfig, {\n runWebpackSpan,\n inputFileSystem,\n })\n debug(`server compiler finished ${Date.now() - start}ms`)\n }\n\n if (!compilerName || compilerName === 'edge-server') {\n debug('starting edge-server compiler')\n const start = Date.now()\n ;[edgeServerResult, inputFileSystem] = edgeConfig\n ? await runCompiler(edgeConfig, { runWebpackSpan, inputFileSystem })\n : [null]\n debug(`edge-server compiler finished ${Date.now() - start}ms`)\n }\n\n // Only continue if there were no errors\n if (!serverResult?.errors.length && !edgeServerResult?.errors.length) {\n const pluginState = getPluginState()\n for (const key in pluginState.injectedClientEntries) {\n const value = pluginState.injectedClientEntries[key]\n const clientEntry = clientConfig.entry as webpack.EntryObject\n if (key === APP_CLIENT_INTERNALS) {\n clientEntry[CLIENT_STATIC_FILES_RUNTIME_MAIN_APP] = {\n import: [\n // TODO-APP: cast clientEntry[CLIENT_STATIC_FILES_RUNTIME_MAIN_APP] to type EntryDescription once it's available from webpack\n // @ts-expect-error clientEntry['main-app'] is type EntryDescription { import: ... }\n ...clientEntry[CLIENT_STATIC_FILES_RUNTIME_MAIN_APP].import,\n value,\n ],\n layer: WEBPACK_LAYERS.appPagesBrowser,\n }\n } else {\n clientEntry[key] = {\n dependOn: [CLIENT_STATIC_FILES_RUNTIME_MAIN_APP],\n import: value,\n layer: WEBPACK_LAYERS.appPagesBrowser,\n }\n }\n }\n\n if (!compilerName || compilerName === 'client') {\n debug('starting client compiler')\n const start = Date.now()\n ;[clientResult, inputFileSystem] = await runCompiler(clientConfig, {\n runWebpackSpan,\n inputFileSystem,\n })\n debug(`client compiler finished ${Date.now() - start}ms`)\n }\n }\n\n if (config.experimental.webpackMemoryOptimizations) {\n stringBufferUtils.exitStringInterningRange()\n }\n inputFileSystem?.purge?.()\n\n result = {\n warnings: [\n ...(clientResult?.warnings ?? []),\n ...(serverResult?.warnings ?? []),\n ...(edgeServerResult?.warnings ?? []),\n ].filter(nonNullable),\n errors: [\n ...(clientResult?.errors ?? []),\n ...(serverResult?.errors ?? []),\n ...(edgeServerResult?.errors ?? []),\n ].filter(nonNullable),\n stats: [\n clientResult?.stats,\n serverResult?.stats,\n edgeServerResult?.stats,\n ],\n }\n })\n result = nextBuildSpan\n .traceChild('format-webpack-messages')\n .traceFn(() => formatWebpackMessages(result, true)) as CompilerResult\n\n const telemetryPlugin = (clientConfig as webpack.Configuration).plugins?.find(\n isTelemetryPlugin\n )\n\n const traceEntryPointsPlugin = (\n serverConfig as webpack.Configuration\n ).plugins?.find(isTraceEntryPointsPlugin)\n\n const webpackBuildEnd = process.hrtime(webpackBuildStart)\n\n if (result.errors.length > 0) {\n // Only keep the first few errors. Others are often indicative\n // of the same problem, but confuse the reader with noise.\n if (result.errors.length > 5) {\n result.errors.length = 5\n }\n let error = result.errors.filter(Boolean).join('\\n\\n')\n\n console.error(red('Failed to compile.\\n'))\n\n if (\n error.indexOf('private-next-pages') > -1 &&\n error.indexOf('does not contain a default export') > -1\n ) {\n const page_name_regex = /'private-next-pages\\/(?<page_name>[^']*)'/\n const parsed = page_name_regex.exec(error)\n const page_name = parsed && parsed.groups && parsed.groups.page_name\n throw new Error(\n `webpack build failed: found page without a React Component as default export in pages/${page_name}\\n\\nSee https://nextjs.org/docs/messages/page-without-valid-component for more info.`\n )\n }\n\n console.error(error)\n console.error()\n\n if (\n error.indexOf('private-next-pages') > -1 ||\n error.indexOf('__next_polyfill__') > -1\n ) {\n const err = new Error(\n 'webpack config.resolve.alias was incorrectly overridden. https://nextjs.org/docs/messages/invalid-resolve-alias'\n ) as NextError\n err.code = 'INVALID_RESOLVE_ALIAS'\n throw err\n }\n const err = new Error(\n `Build failed because of ${process.env.NEXT_RSPACK ? 'Rspack' : 'webpack'} errors`\n ) as NextError\n err.code = 'WEBPACK_ERRORS'\n throw err\n } else {\n const duration = hrtimeToSeconds(webpackBuildEnd)\n const durationString = durationToString(duration)\n\n if (result.warnings.length > 0) {\n Log.warn(`Compiled with warnings in ${durationString}\\n`)\n console.warn(result.warnings.filter(Boolean).join('\\n\\n'))\n console.warn()\n } else if (!compilerName) {\n Log.event(`Compiled successfully in ${durationString}`)\n }\n\n return {\n duration,\n buildTraceContext: traceEntryPointsPlugin?.buildTraceContext,\n pluginState: getPluginState(),\n telemetryState: {\n usages: telemetryPlugin?.usages() || [],\n packagesUsedInServerSideProps:\n telemetryPlugin?.packagesUsedInServerSideProps() || [],\n useCacheTracker: telemetryPlugin?.getUseCacheTracker() || {},\n },\n }\n }\n}\n\n// the main function when this file is run as a worker\nexport async function workerMain(workerData: {\n compilerName: keyof typeof COMPILER_INDEXES\n buildContext: typeof NextBuildContext\n traceState: TraceState\n}): Promise<\n Awaited<ReturnType<typeof webpackBuildImpl>> & {\n debugTraceEvents: TraceEvent[]\n }\n> {\n // Clone the telemetry for worker\n const telemetry = new Telemetry({\n distDir: workerData.buildContext.config!.distDir,\n })\n setGlobal('telemetry', telemetry)\n // setup new build context from the serialized data passed from the parent\n Object.assign(NextBuildContext, workerData.buildContext)\n\n // Initialize tracer state from the parent\n initializeTraceState(workerData.traceState)\n\n // Resume plugin state\n resumePluginState(NextBuildContext.pluginState)\n\n /// load the config because it's not serializable\n NextBuildContext.config = await loadConfig(\n PHASE_PRODUCTION_BUILD,\n NextBuildContext.dir!,\n { debugPrerender: NextBuildContext.debugPrerender }\n )\n NextBuildContext.nextBuildSpan = trace(\n `worker-main-${workerData.compilerName}`\n )\n\n const result = await webpackBuildImpl(workerData.compilerName)\n const { entriesTrace, chunksTrace } = result.buildTraceContext ?? {}\n if (entriesTrace) {\n const { entryNameMap, depModArray } = entriesTrace\n if (depModArray) {\n result.buildTraceContext!.entriesTrace!.depModArray = depModArray\n }\n if (entryNameMap) {\n const entryEntries = entryNameMap\n result.buildTraceContext!.entriesTrace!.entryNameMap = entryEntries\n }\n }\n if (chunksTrace?.entryNameFilesMap) {\n const entryNameFilesMap = chunksTrace.entryNameFilesMap\n result.buildTraceContext!.chunksTrace!.entryNameFilesMap = entryNameFilesMap\n }\n NextBuildContext.nextBuildSpan.stop()\n return { ...result, debugTraceEvents: getTraceEvents() }\n}\n"],"names":["stringBufferUtils","red","formatWebpackMessages","nonNullable","COMPILER_NAMES","CLIENT_STATIC_FILES_RUNTIME_MAIN_APP","APP_CLIENT_INTERNALS","PHASE_PRODUCTION_BUILD","runCompiler","Log","getBaseWebpackConfig","loadProjectInfo","TelemetryPlugin","NextBuildContext","resumePluginState","getPluginState","createEntrypoints","loadConfig","getTraceEvents","initializeTraceState","setGlobal","trace","WEBPACK_LAYERS","TraceEntryPointsPlugin","origDebug","Telemetry","durationToString","debug","hrtimeToSeconds","hrtime","isTelemetryPlugin","plugin","isTraceEntryPointsPlugin","webpackBuildImpl","compilerName","result","warnings","errors","stats","webpackBuildStart","nextBuildSpan","dir","config","process","env","NEXT_COMPILER_NAME","runWebpackSpan","traceChild","entrypoints","traceAsyncFn","buildId","envFiles","loadedEnvFiles","isDev","rootDir","pageExtensions","pagesDir","appDir","pages","mappedPages","appPaths","mappedAppPages","previewMode","previewProps","rootPaths","mappedRootPaths","hasInstrumentationHook","commonWebpackOptions","isServer","isCompileMode","encryptionKey","rewrites","originalRewrites","originalRedirects","reactProductionProfiling","noMangling","clientRouterFilters","allowedRevalidateHeaderKeys","fetchCacheKeyPrefix","configs","info","dev","Promise","all","middlewareMatchers","compilerType","client","server","edgeServer","clientConfig","serverConfig","edgeConfig","optimization","minimize","minimizer","length","warn","inputFileSystem","experimental","webpackMemoryOptimizations","disableDualStringBufferCaching","enterStringInterningRange","clientResult","serverResult","edgeServerResult","start","Date","now","pluginState","key","injectedClientEntries","value","clientEntry","entry","import","layer","appPagesBrowser","dependOn","exitStringInterningRange","purge","filter","traceFn","telemetryPlugin","plugins","find","traceEntryPointsPlugin","webpackBuildEnd","error","Boolean","join","console","indexOf","page_name_regex","parsed","exec","page_name","groups","Error","err","code","NEXT_RSPACK","duration","durationString","event","buildTraceContext","telemetryState","usages","packagesUsedInServerSideProps","useCacheTracker","getUseCacheTracker","workerMain","workerData","telemetry","distDir","buildContext","Object","assign","traceState","debugPrerender","entriesTrace","chunksTrace","entryNameMap","depModArray","entryEntries","entryNameFilesMap","stop","debugTraceEvents"],"mappings":"AAAA,OAAO,4BAA2B;AAElC,SAASA,iBAAiB,QAAQ,sCAAqC;AACvE,SAASC,GAAG,QAAQ,uBAAsB;AAC1C,OAAOC,2BAA2B,2CAA0C;AAC5E,SAASC,WAAW,QAAQ,yBAAwB;AAEpD,SACEC,cAAc,EACdC,oCAAoC,EACpCC,oBAAoB,EACpBC,sBAAsB,QACjB,6BAA4B;AACnC,SAASC,WAAW,QAAQ,cAAa;AACzC,YAAYC,SAAS,gBAAe;AACpC,OAAOC,wBAAwBC,eAAe,QAAQ,oBAAmB;AAEzE,SACEC,eAAe,QAEV,uDAAsD;AAC7D,SACEC,gBAAgB,EAChBC,iBAAiB,EACjBC,cAAc,QACT,mBAAkB;AACzB,SAASC,iBAAiB,QAAQ,aAAY;AAC9C,OAAOC,gBAAgB,sBAAqB;AAC5C,SACEC,cAAc,EACdC,oBAAoB,EACpBC,SAAS,EACTC,KAAK,QAGA,cAAa;AACpB,SAASC,cAAc,QAAQ,sBAAqB;AACpD,SAASC,sBAAsB,QAAQ,mDAAkD;AAIzF,OAAOC,eAAe,2BAA0B;AAChD,SAASC,SAAS,QAAQ,0BAAyB;AACnD,SAASC,gBAAgB,QAAQ,wBAAuB;AAExD,MAAMC,QAAQH,UAAU;AAExB,SAASI,gBAAgBC,MAAwB;IAC/C,8CAA8C;IAC9C,OAAOA,MAAM,CAAC,EAAE,GAAGA,MAAM,CAAC,EAAE,GAAG;AACjC;AAcA,SAASC,kBAAkBC,MAAe;IACxC,OAAOA,kBAAkBnB;AAC3B;AAEA,SAASoB,yBACPD,MAAe;IAEf,OAAOA,kBAAkBR;AAC3B;AAEA,OAAO,eAAeU,iBACpBC,YAAkD;QAuN1B,uBAIO;IApN/B,IAAIC,SAAgC;QAClCC,UAAU,EAAE;QACZC,QAAQ,EAAE;QACVC,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V,wBACAM,iBAAiB4B,GAAG,EACpB;QAAEqH,gBAAgBjJ,iBAAiBiJ,cAAc;IAAC;IAEpDjJ,iBAAiB2B,aAAa,GAAGnB,MAC/B,CAAC,YAAY,EAAEkI,WAAWrH,YAAY,EAAE;IAG1C,MAAMC,SAAS,MAAMF,iBAAiBsH,WAAWrH,YAAY;IAC7D,MAAM,EAAE6H,YAAY,EAAEC,WAAW,EAAE,GAAG7H,OAAO6G,iBAAiB,IAAI,CAAC;IACnE,IAAIe,cAAc;QAChB,MAAM,EAAEE,YAAY,EAAEC,WAAW,EAAE,GAAGH;QACtC,IAAIG,aAAa;YACf/H,OAAO6G,iBAAiB,CAAEe,YAAY,CAAEG,WAAW,GAAGA;QACxD;QACA,IAAID,cAAc;YAChB,MAAME,eAAeF;YACrB9H,OAAO6G,iBAAiB,CAAEe,YAAY,CAAEE,YAAY,GAAGE;QACzD;IACF;IACA,IAAIH,+BAAAA,YAAaI,iBAAiB,EAAE;QAClC,MAAMA,oBAAoBJ,YAAYI,iBAAiB;QACvDjI,OAAO6G,iBAAiB,CAAEgB,WAAW,CAAEI,iBAAiB,GAAGA;IAC7D;IACAvJ,iBAAiB2B,aAAa,CAAC6H,IAAI;IACnC,OAAO;QAAE,GAAGlI,MAAM;QAAEmI,kBAAkBpJ;IAAiB;AACzD","ignoreList":[0]}
|
|
@@ -1575,7 +1575,7 @@ export default async function getBaseWebpackConfig(dir, { buildId, encryptionKey
|
|
|
1575
1575
|
isClient && new CopyFilePlugin({
|
|
1576
1576
|
// file path to build output of `@next/polyfill-nomodule`
|
|
1577
1577
|
filePath: require.resolve('./polyfills/polyfill-nomodule'),
|
|
1578
|
-
cacheKey: "15.6.0-bun.
|
|
1578
|
+
cacheKey: "15.6.0-bun.16",
|
|
1579
1579
|
name: `static/chunks/polyfills${dev ? '' : '-[hash]'}.js`,
|
|
1580
1580
|
minimize: false,
|
|
1581
1581
|
info: {
|
|
@@ -1756,7 +1756,7 @@ export default async function getBaseWebpackConfig(dir, { buildId, encryptionKey
|
|
|
1756
1756
|
// - Next.js location on disk (some loaders use absolute paths and some resolve options depend on absolute paths)
|
|
1757
1757
|
// - Next.js version
|
|
1758
1758
|
// - next.config.js keys that affect compilation
|
|
1759
|
-
version: `${__dirname}|${"15.6.0-bun.
|
|
1759
|
+
version: `${__dirname}|${"15.6.0-bun.16"}|${configVars}`,
|
|
1760
1760
|
cacheDirectory: path.join(distDir, 'cache', 'webpack'),
|
|
1761
1761
|
// For production builds, it's more efficient to compress all cache files together instead of compression each one individually.
|
|
1762
1762
|
// So we disable compression here and allow the build runner to take care of compressing the cache as a whole.
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* - next/script with `beforeInteractive` strategy
|
|
6
6
|
*/ import { getAssetPrefix } from './asset-prefix';
|
|
7
7
|
import { setAttributesFromProps } from './set-attributes-from-props';
|
|
8
|
-
const version = "15.6.0-bun.
|
|
8
|
+
const version = "15.6.0-bun.16";
|
|
9
9
|
window.next = {
|
|
10
10
|
version,
|
|
11
11
|
appDir: true
|
package/dist/esm/client/index.js
CHANGED
|
@@ -26,7 +26,7 @@ import { SearchParamsContext, PathParamsContext } from '../shared/lib/hooks-clie
|
|
|
26
26
|
import { onRecoverableError } from './react-client-callbacks/on-recoverable-error';
|
|
27
27
|
import tracer from './tracing/tracer';
|
|
28
28
|
import { isNextRouterError } from './components/is-next-router-error';
|
|
29
|
-
export const version = "15.6.0-bun.
|
|
29
|
+
export const version = "15.6.0-bun.16";
|
|
30
30
|
export let router;
|
|
31
31
|
export const emitter = mitt();
|
|
32
32
|
const looseToArray = (input)=>[].slice.call(input);
|
|
@@ -158,7 +158,7 @@ export default class HotReloaderWebpack {
|
|
|
158
158
|
this.previewProps = previewProps;
|
|
159
159
|
this.rewrites = rewrites;
|
|
160
160
|
this.hotReloaderSpan = trace('hot-reloader', undefined, {
|
|
161
|
-
version: "15.6.0-bun.
|
|
161
|
+
version: "15.6.0-bun.16"
|
|
162
162
|
});
|
|
163
163
|
// Ensure the hotReloaderSpan is flushed immediately as it's the parentSpan for all processing
|
|
164
164
|
// of the current `next dev` invocation.
|
|
@@ -14,7 +14,7 @@ export function logStartInfo({ networkUrl, appUrl, envInfo, experimentalFeatures
|
|
|
14
14
|
bundlerSuffix = ' (webpack)';
|
|
15
15
|
}
|
|
16
16
|
}
|
|
17
|
-
Log.bootstrap(`${bold(purple(`${Log.prefixes.ready} Next.js ${"15.6.0-bun.
|
|
17
|
+
Log.bootstrap(`${bold(purple(`${Log.prefixes.ready} Next.js ${"15.6.0-bun.16"}`))}${bundlerSuffix}`);
|
|
18
18
|
if (appUrl) {
|
|
19
19
|
Log.bootstrap(`- Local: ${appUrl}`);
|
|
20
20
|
}
|
|
@@ -87,7 +87,7 @@ export async function getRequestHandlers({ dir, port, isDev, onDevServerCleanup,
|
|
|
87
87
|
export async function startServer(serverOptions) {
|
|
88
88
|
const { dir, isDev, hostname, minimalMode, allowRetry, keepAliveTimeout, selfSignedCertificate } = serverOptions;
|
|
89
89
|
let { port } = serverOptions;
|
|
90
|
-
process.title = `next-server (v${"15.6.0-bun.
|
|
90
|
+
process.title = `next-server (v${"15.6.0-bun.16"})`;
|
|
91
91
|
let handlersReady = ()=>{};
|
|
92
92
|
let handlersError = ()=>{};
|
|
93
93
|
let handlersPromise = new Promise((resolve, reject)=>{
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export function isStableBuild() {
|
|
2
2
|
var _process_env___NEXT_VERSION;
|
|
3
|
-
return !((_process_env___NEXT_VERSION = "15.6.0-bun.
|
|
3
|
+
return !((_process_env___NEXT_VERSION = "15.6.0-bun.16") == null ? void 0 : _process_env___NEXT_VERSION.includes('canary')) && !process.env.__NEXT_TEST_MODE && !process.env.NEXT_PRIVATE_LOCAL_DEV;
|
|
4
4
|
}
|
|
5
5
|
export class CanaryOnlyError extends Error {
|
|
6
6
|
constructor(arg){
|
|
@@ -226,7 +226,7 @@ class HotReloaderWebpack {
|
|
|
226
226
|
this.previewProps = previewProps;
|
|
227
227
|
this.rewrites = rewrites;
|
|
228
228
|
this.hotReloaderSpan = (0, _trace.trace)('hot-reloader', undefined, {
|
|
229
|
-
version: "15.6.0-bun.
|
|
229
|
+
version: "15.6.0-bun.16"
|
|
230
230
|
});
|
|
231
231
|
// Ensure the hotReloaderSpan is flushed immediately as it's the parentSpan for all processing
|
|
232
232
|
// of the current `next dev` invocation.
|
|
@@ -82,7 +82,7 @@ function logStartInfo({ networkUrl, appUrl, envInfo, experimentalFeatures, logBu
|
|
|
82
82
|
bundlerSuffix = ' (webpack)';
|
|
83
83
|
}
|
|
84
84
|
}
|
|
85
|
-
_log.bootstrap(`${(0, _picocolors.bold)((0, _picocolors.purple)(`${_log.prefixes.ready} Next.js ${"15.6.0-bun.
|
|
85
|
+
_log.bootstrap(`${(0, _picocolors.bold)((0, _picocolors.purple)(`${_log.prefixes.ready} Next.js ${"15.6.0-bun.16"}`))}${bundlerSuffix}`);
|
|
86
86
|
if (appUrl) {
|
|
87
87
|
_log.bootstrap(`- Local: ${appUrl}`);
|
|
88
88
|
}
|
|
@@ -155,7 +155,7 @@ async function getRequestHandlers({ dir, port, isDev, onDevServerCleanup, server
|
|
|
155
155
|
async function startServer(serverOptions) {
|
|
156
156
|
const { dir, isDev, hostname, minimalMode, allowRetry, keepAliveTimeout, selfSignedCertificate } = serverOptions;
|
|
157
157
|
let { port } = serverOptions;
|
|
158
|
-
process.title = `next-server (v${"15.6.0-bun.
|
|
158
|
+
process.title = `next-server (v${"15.6.0-bun.16"})`;
|
|
159
159
|
let handlersReady = ()=>{};
|
|
160
160
|
let handlersError = ()=>{};
|
|
161
161
|
let handlersPromise = new Promise((resolve, reject)=>{
|
|
@@ -22,7 +22,7 @@ _export(exports, {
|
|
|
22
22
|
});
|
|
23
23
|
function isStableBuild() {
|
|
24
24
|
var _process_env___NEXT_VERSION;
|
|
25
|
-
return !((_process_env___NEXT_VERSION = "15.6.0-bun.
|
|
25
|
+
return !((_process_env___NEXT_VERSION = "15.6.0-bun.16") == null ? void 0 : _process_env___NEXT_VERSION.includes('canary')) && !process.env.__NEXT_TEST_MODE && !process.env.NEXT_PRIVATE_LOCAL_DEV;
|
|
26
26
|
}
|
|
27
27
|
class CanaryOnlyError extends Error {
|
|
28
28
|
constructor(arg){
|
|
@@ -11,11 +11,11 @@ Object.defineProperty(exports, "eventCliSessionStopped", {
|
|
|
11
11
|
const EVENT_VERSION = 'NEXT_CLI_SESSION_STOPPED';
|
|
12
12
|
function eventCliSessionStopped(event) {
|
|
13
13
|
// This should be an invariant, if it fails our build tooling is broken.
|
|
14
|
-
if (typeof "15.6.0-bun.
|
|
14
|
+
if (typeof "15.6.0-bun.16" !== 'string') {
|
|
15
15
|
return [];
|
|
16
16
|
}
|
|
17
17
|
const payload = {
|
|
18
|
-
nextVersion: "15.6.0-bun.
|
|
18
|
+
nextVersion: "15.6.0-bun.16",
|
|
19
19
|
nodeVersion: process.version,
|
|
20
20
|
cliCommand: event.cliCommand,
|
|
21
21
|
durationMilliseconds: event.durationMilliseconds,
|
|
@@ -12,12 +12,12 @@ const EVENT_VERSION = 'NEXT_CLI_SESSION_STARTED';
|
|
|
12
12
|
function eventCliSession(nextConfig, event) {
|
|
13
13
|
var _nextConfig_experimental_staleTimes, _nextConfig_experimental_staleTimes1, _nextConfig_experimental_reactCompiler, _nextConfig_experimental_reactCompiler1;
|
|
14
14
|
// This should be an invariant, if it fails our build tooling is broken.
|
|
15
|
-
if (typeof "15.6.0-bun.
|
|
15
|
+
if (typeof "15.6.0-bun.16" !== 'string') {
|
|
16
16
|
return [];
|
|
17
17
|
}
|
|
18
18
|
const { images, i18n } = nextConfig || {};
|
|
19
19
|
const payload = {
|
|
20
|
-
nextVersion: "15.6.0-bun.
|
|
20
|
+
nextVersion: "15.6.0-bun.16",
|
|
21
21
|
nodeVersion: process.version,
|
|
22
22
|
cliCommand: event.cliCommand,
|
|
23
23
|
isSrcDir: event.isSrcDir,
|