![](https://img-blog.csdnimg.cn/20201014180756738.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
vue
yq612
这个作者很懒,什么都没留下…
展开
-
[unplugin-vue-components] component “xx“ has naming conflicts with other components, ignored.
[unplugin-vue-components] component “xx“ has naming conflicts with other components, ignored.原创 2022-02-17 16:09:25 · 3142 阅读 · 0 评论 -
Error: .plugins[0][1] must be an object, false, or undefined
问题产生babel.config.js的plugins队列中,每个队列第二个参数不支持数组,所以报错问题分析翻看babel-plugin-import发现,其实是babel版本问题:Options can't be an array in babel@7+,所以要想使用数组就要使用兼容性写法解决方案使用两个队列// .babelrc plugins: [ ['some-pl...原创 2020-01-05 22:33:15 · 1141 阅读 · 0 评论 -
vue-cli3使用less全局变量
vue-cl3安装less之后默认无法使用全局变量,需要额外添加插件解决方案安装插件vue add style-resources-loader新建一个less文件存放全局变量修改配置,进入vue.config.js(不存在就在项目根目录创建一个)const path = require('path')module.exports = { pluginOptions: ...原创 2019-11-29 10:50:28 · 838 阅读 · 0 评论 -
关于 Array.apply(null, { length:20 }).map() 的思考
vue的render的文档中出现了,用来循环生成元素。是什么本质是函数式编程的循环方法。就是一种循环方法,你用for循环代替,效果也是一样的,但是Array.apply(null, { length: 20 }).map()算是函数式编程怎么实现函数式编程中的循环如果不用for,你脑海中可能马上会想起reduce,forEach,map这些迭代器函数,都能产生循环。比如:[1,2,3]...原创 2019-11-25 20:22:19 · 627 阅读 · 2 评论