vue
文章平均质量分 99
聆枫web
这个作者很懒,什么都没留下…
展开
-
uniapp搭建多端项目
文章目录前言一、项目搭建1. 多域名指向考虑2. gitlab 自动化构建打包3. 请求接口的封装二、开发运用技巧1.分包式项目布局2. 运用uni封装uniCrazyRouter路由拦截3. 商品多规格实现思路4. 封装组件地址联动更改三、避坑记前言在开发中会为了结合业务要求,多端开发节省开发的时间,为此运用了uniapp 开发出兼容于H5,小程序的多端开发适应。uniapp开发写法好处就是语法上是基于vue写法,写法格式是根据小程序的走,除了基本的vue的格式也引用了小程序特有点的比如onLoad原创 2021-03-26 15:32:05 · 2137 阅读 · 0 评论 -
基于vue的UI框架ydui中的楼层跳跃scrolltab问题解决
资料链接 scrolltab实现楼层点击切换需求实现点击左侧一级,呈现右侧二三级的数据,要求需要很顺畅,不能卡顿现象常规实现实现: 遍历出需要一级的数据,通过点击一级将id传给二三级的数据接口,创建出空数组,通过创建销毁的过程不断将二三级的数据添加到空数组中问题:此时会出现很卡顿现在,数据一直在加载中,但是数据接口请求很快,而前端渲染很慢现象。网友解决方法: 图片懒加载,虚拟列...原创 2019-11-28 19:06:21 · 669 阅读 · 0 评论 -
【NPM】npm ERR! Unexpected end of JSON input while parsing near '…",'解决方案
【NPM】npm ERR! Unexpected end of JSON input while parsing near '…",'解决方案今天安装项目依赖npm install 的时候出现错误:npm ERR! Unexpected end of JSON input while parsing near '...e":"^23.5.0","listr":'npm cache c...原创 2019-05-13 22:12:17 · 137 阅读 · 0 评论 -
vue增删加
删除实现<button class="del" @click="$emit('deleteItem',todo.id)">x</button>Todoitem @click="$emit(‘deleteItem’,todo.id)" >Todos @deleteItem="$emit(‘handleDelete’,todo.id)" >App ...原创 2019-06-17 01:51:14 · 452 阅读 · 0 评论 -
element-ui/lib/from in ./src/plugins/element.js 这种错误的解决
使用element遇见问题错误: These dependencies were not found:element-ui/lib/from in ./src/plugins/element.jselement-ui/lib/theme-chalk/from.css in ./src/plugins/element.js*这种一般有两种情况: 2. ele ui 没引入丢包的情...原创 2019-07-14 11:25:30 · 5411 阅读 · 4 评论 -
关闭浏览器窗口的时候清空浏览器缓存在localStorage的数据
在App.vuemounted(){ // 关闭浏览器窗口的时候清空浏览器缓存在localStorage的数据 window.onbeforeunload = function (e) { var storage = window.sessionStorage; storage.clear() ...原创 2019-08-01 20:23:20 · 5747 阅读 · 3 评论 -
vue中实现多个弹窗,单一的点击关闭
<div class="payment_box" v-for="(item,index) in bannerList8" :key="item.id" v-show="pay_isclose.indexOf(index) == -1"> <div class="pay_box" > <div class="close" @click="c...原创 2019-08-01 20:58:10 · 2702 阅读 · 0 评论 -
拼接的链接,跳转到列表页,需求:取到拼接的coupon_id将它带到列表页中
列表中api请求,原本的接口 /index.php?m=Home&c=api.Goods&a=goodsList需要加上&coupon_id=coupon_id 即为/index.php?m=Home&c=api.Goods&a=goodsList&coupon_id=coupon_idexport const goods_lists = (p...原创 2019-08-01 21:07:42 · 860 阅读 · 0 评论