Skip to content

Commit 45aca81

Browse files
authored
fix: "commonjs2" target should not be used with "output.library" (#6218)
Closes #6188
1 parent 82aef12 commit 45aca81

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

packages/@vue/cli-service/lib/commands/build/resolveLibConfig.js

+5
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,11 @@ module.exports = (api, { entry, name, formats, filename, 'inline-vue': inlineVue
129129
publicPath: ''
130130
})
131131

132+
if (format === 'commonjs2') {
133+
// #6188
134+
delete rawConfig.output.library
135+
}
136+
132137
return rawConfig
133138
}
134139

0 commit comments

Comments
 (0)