webpack 2 + babel loader配置-生产配置是否应排除node_modules?

问题描述 投票:0回答:0

我正在尝试了解webpack 2和babel-loader文档,但是我对exclude选项感到困惑。

这就是我的意思:

{
  test: /\.jsx?$/,
  use: 'babel-loader',
  exclude: 'node_modules',
  include: 'app'
}

Include将使用该加载程序来处理'app'中匹配的文件,但是我是否需要对node_modules执行此node_modules

谢谢

javascript webpack
© www.soinside.com 2019 - 2024. All rights reserved.