npm install
npm run serve
npm run build
npm run lint
-
组件中的 data 为什么是一个函数: vue 中组件是用来复用的,为了防止 data 复用,将其定义为函数。 https://blog.csdn.net/qq_42072086/article/details/108060494
-
computed 和 watch 区别: https://www.cnblogs.com/wuqilang/p/11241604.html
-
CDN引入资源:https://blog.csdn.net/sixam/article/details/106058083
-
临时变量:在v-for中需要对每一项的数据处理,在重复使用的时候会造成重复计算和执行,所以需要使用临时变量存储。https://forum.vuejs.org/t/topic/30395/5,category.vue 文件中有实例。