前言
引入导致,因为webpackMerge的却不是一个函数呀~
内容
?> 正确示范
const webpackMerge = require('webpack-merge') module.exports = webpackMerge.merge(webpackBaseConfig, webpackProdConfig) # 直接引用merge函数 const { merge } = require('webpack-merge') module.exports = merge(webpackBaseConfig, webpackProdConfig)
!> 错误示范
const webpackMerge = require('webpack-merge') module.exports = webpackMerge(webpackBaseConfig, webpackProdConfig)
学无止境,谦卑而行.