Environment
- Operating System: Linux
- Node Version: v22.12.0
- Nuxt Version: 2.18.1
- CLI Version: 3.30.0
- Nitro Version: 2.12.5
- Package Manager: [email protected]
- Builder: webpack
- User Config: -
- Runtime Modules: -
- Build Modules: -
Reproduction
Describe the bug
export default defineNuxtConfig({
app: { cdnURL: 'http://static.local.jeeda.net' },
bridge: {
capi: { legacy: false },
typescript: true,
nitro: true,
transpile: true,
meta: true,
vite: false,
},
nitro: {
....
}
})
When I configure cdnURL and enable nitro, I can find that cdnURL also covers build.publicPath through the setupNitroBridge function in bridge/src/nitro.ts. At the same time, publicPath will take effect in the webpack build. You can see it by printing config from the build.extend configuration.
Eventually this will lead to a problem: resources dynamically loaded through webpack will have path splicing errors, like this

Additional context
No response
Logs