提交 6a760fc3 编写于 作者: fxy060608's avatar fxy060608

fix(mp): move node_modules to vendor chunk

上级 36c65246
......@@ -67,7 +67,7 @@ function createMoveToVendorChunkFn(): GetManualChunk {
const filename = id.split('?')[0]
// 处理项目内的js,ts文件
if (EXTNAME_JS_RE.test(filename)) {
if (filename.startsWith(inputDir)) {
if (filename.startsWith(inputDir) && !filename.includes('node_modules')) {
const chunkFileName = removeExt(
normalizePath(path.relative(inputDir, filename))
)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册