babel-loader should exclude node_modules on testing iview*.js
- Dominant language
- JavaScript
- Stars
- 721
- Forks
- 139
- PR merge metrics
- No merged PRs in 30d
Description
webpack.base.config.js中与iview*.js对应的babel-loader规则也许应该加上: exclude: /node_modules/
```javascript
{
test: /iview\/.*?js$/,
loader: 'babel-loader'
exclude: /node_modules/ <------少了这一行,this line should be added
},
{
test: /\.js$/,
loader: 'babel-loader',
exclude: /node_modules/
},
```
不加的话,执行webpack时,windows下没问题,在linux上会报`[BABEL] Note: The code generator has deoptimised the styling of "..." as it exceeds the max of "500KB".` 最终编译出来的静态文件会报错
具体请参见:
- (https://github.com/0xffff00/skfe/issues/20#issuecomment-359155368)
- (https://github.com/babel/babel/issues/6041#issuecomment-319589192)
Contributor guide
No contributing guide indexed for this repository
Research direction
Open webpack.base.config.js and inspect the babel-loader rule matching iview/*.js. Compare it with the adjacent JavaScript rule, then run webpack on Linux to verify that the generated static files no longer fail with the reported Babel warning or resulting error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, webpack
- Domain
- build-system, cli
- Issue type
- Bug
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 50/100