File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -37,8 +37,7 @@ module.exports.pitch = function (remainingRequest) {
3737 ...beforeLoaders
3838 ] )
3939 // console.log(request)
40- // use cjs to ensure exports from (vue-)style-loader/css-loader are intact
41- return `module.exports = require(${ request } )`
40+ return `import mod from ${ request } ; export default mod; export * from ${ request } `
4241 }
4342 }
4443
@@ -66,5 +65,5 @@ module.exports.pitch = function (remainingRequest) {
6665 // both that rule and the cloned rule will match, resulting in duplicated
6766 // loaders. Therefore it is necessary to perform a dedupe here.
6867 const request = genRequest ( loaders . map ( toLoaderString ) )
69- return `module.exports = require( ${ request } ) `
68+ return `import mod from ${ request } ; export default mod; export * from ${ request } `
7069}
You can’t perform that action at this time.
0 commit comments