File tree Expand file tree Collapse file tree 1 file changed +5
-8
lines changed
packages/next/src/build/webpack/loaders/next-flight-loader Expand file tree Collapse file tree 1 file changed +5
-8
lines changed Original file line number Diff line number Diff line change @@ -104,20 +104,17 @@ export default function transformSource(
104
104
let esmSource = `\
105
105
import { createProxy } from "${ MODULE_PROXY_PATH } "
106
106
107
- const proxy = createProxy(String.raw\`${ this . resourcePath } \`)
107
+ const proxy = createProxy(String.raw\`${ resourceKey } \`)
108
108
`
109
109
let cnt = 0
110
110
for ( const ref of clientRefs ) {
111
111
if ( ref === '' ) {
112
- esmSource += `\nexports [''] = proxy['']; `
112
+ esmSource += `exports [''] = proxy['']\n `
113
113
} else if ( ref === 'default' ) {
114
- esmSource += `\
115
- export default createProxy(String.raw\`${ resourceKey } #default\`);
116
- `
114
+ esmSource += `export default createProxy(String.raw\`${ resourceKey } #default\`)\n`
117
115
} else {
118
- esmSource += `
119
- const e${ cnt } = proxy["${ ref } "];
120
- export { e${ cnt ++ } as ${ ref } };`
116
+ esmSource += `const e${ cnt } = proxy["${ ref } "];\n`
117
+ esmSource += `export { e${ cnt } as ${ ref } };\n`
121
118
}
122
119
}
123
120
You can’t perform that action at this time.
0 commit comments