2020年11月4日
摘要: 1、安装项目需要使用的npm包 yarn add webpack-merge cross-env html-webpack-plugin clean-webpack-plugin babel-loader @babel/core //cross-env设置打包env 2、在项目根目录下新建build 阅读全文
posted @ 2020-11-04 22:04 随心的博客 阅读(541) 评论(0) 推荐(0) 编辑
摘要: 1、安装配置babel yarn add babel-loader @babel/core @babel/preset-env 2、webpack.config.js配置module module: { rules: [ { test: /\.js$/, exclude: /node_modules 阅读全文
posted @ 2020-11-04 21:56 随心的博客 阅读(808) 评论(0) 推荐(1) 编辑
摘要: 1、安装lodash yarn add lodash 2、使用es5实现函数柯里化 function add(a, b) { return function (c, d) { // console.log(a + b + c + d) return a + b + c + d } } let num 阅读全文
posted @ 2020-11-04 11:37 随心的博客 阅读(227) 评论(0) 推荐(0) 编辑