File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -285,10 +285,9 @@ export default function VuePlugin(opts: VuePluginOptions = {}): Plugin {
285
285
export default script
286
286
// For security concerns, we use only base name in production mode. See https://github.com/vuejs/rollup-plugin-vue/issues/258
287
287
script.__file = ${ isProduction ? JSON . stringify ( path . basename ( filename ) ) : JSON . stringify ( filename ) }
288
- ` ,
289
- map : { mappings : '' } ,
288
+ `
290
289
}
291
- : { code : '' , map : { mappings : '' } }
290
+ : { code : '' }
292
291
293
292
if ( shouldExtractCss ) {
294
293
input . styles = input . styles
@@ -305,7 +304,7 @@ export default function VuePlugin(opts: VuePluginOptions = {}): Plugin {
305
304
) } '`
306
305
307
306
if ( style . module || descriptor . styles [ index ] . scoped ) {
308
- return { ...style , code : '' , map : { mappings : '' } }
307
+ return { ...style , code : '' , map : undefined }
309
308
}
310
309
} )
311
310
. filter ( Boolean )
@@ -331,6 +330,8 @@ export default function VuePlugin(opts: VuePluginOptions = {}): Plugin {
331
330
332
331
dT ( `id: ${ filename } \ncode:\n${ result . code } \n\nmap:\n${ JSON . stringify ( result . map , null , 2 ) } \n` )
333
332
333
+ result . map = result . map || { mappings : '' }
334
+
334
335
return result
335
336
}
336
337
} ,
You can’t perform that action at this time.
0 commit comments