webpack中Tree-shaking Tree-shaking即树摇,上图形象地描述其含义。其根本目的是为了在项目构建打包时去掉没有用到的JS代码。 webpack中Tree-shaking参考资料 tree-shaking性能优化原理