Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade webpack to v4 #16

Closed
16slowly opened this issue Jan 8, 2019 · 2 comments
Closed

Upgrade webpack to v4 #16

16slowly opened this issue Jan 8, 2019 · 2 comments
Assignees
Labels
Webpack webpack study
Projects

Comments

@16slowly 16slowly added the Webpack webpack study label Jan 8, 2019
@16slowly 16slowly self-assigned this Jan 8, 2019
@16slowly 16slowly added this to Todo in blog via automation Jan 8, 2019
@16slowly
Copy link
Owner Author

Babel

babel 基础知识

  1. babelbabel-corebabel-loaderbabel-preset-2015babel-preset-reactbabel-polyfillhttps://stackoverflow.com/a/48516794/9617320

babel 7.2

  1. @babel/core vs babel-core: https://stackoverflow.com/a/53395718/9617320
  2. @babel/polyfill vs @babel/plugin-transform-runtime:

+@babel/plugin-proposal-class-properties

Support for the experimental syntax 'classProperties' isn't currently enabled

see babel/babel#8655

+@babel/plugin-proposal-export-default-from

Support for the experimental syntax 'exportDefaultFrom' isn't currently enabled

see babel/babel#7293

🔼babel-eslint: https://github.com/babel/babel-eslint

allow function is no-defined

⚠️注意

  • babel-loader config 与 .babelrc 之间是互斥的

babel 7.1

Support for the experimental syntax 'exportDefaultFrom' isn't currently enabled

babel-preset-stage-1 中内置了这个功能,但 babel-preset-env 中没有,但直接安装 babel-plugin-transform-export-extensions 却报 404, 所以通过安装 babel-preset-stage-1 来进行安装, see https://stackoverflow.com/a/41058960/9617320

@16slowly
Copy link
Owner Author

16slowly commented Jan 17, 2019

Eslint

🔼 eslint-loader: https://github.com/webpack-contrib/eslint-loader/releases/tag/2.0.0
🔼 eslint@4.9.0
🔼 eslint-plugin-react@7.4.0
🔼 eslint-plugin-import@2.7.0
🔼 eslint-plugin-jsx-a11y@6.0.2

其他

  • 查看依赖的 peerDependencies 版本:
   npm info "eslint-config-airbnb@16.0.0" peerDependencies
 { 
   eslint: '^4.9.0',
  'eslint-plugin-jsx-a11y': '^6.0.2',
  'eslint-plugin-import': '^2.7.0',
  'eslint-plugin-react': '^7.4.0' 
}

blog automation moved this from Todo to Done Jan 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Webpack webpack study
Projects
blog
  
Done
Development

No branches or pull requests

1 participant