随笔分类 - vue
vue相关
摘要:1,pagination的配置 pagination: { el: '.swiper-paginationfull', // type:'bullets', // bulletElement : 'span',//设置分页器小圆点标签,默认为span标签 // clickable:true, //
阅读全文
摘要:haha(){ var that=this; that.$refs.mySwiper.swiper.slideTo(1, 1000, false); } //以上代码是 获取ref值为myswiper的实例swiper,之后跳转到第二页,时间为1s,为false时不触发onSlideChange回调
阅读全文
摘要:swiperOption: {//swiper的配置项 notNextTick: true,//想获得swiper实例对象,这个必须为true direction: 'vertical', // grabCursor: true,//鼠标覆盖Swiper时指针会变成手掌形状,拖动时指针会变成抓手形状
阅读全文
摘要:1、先安装less-loader npm install less less-loader --save 2、再安装css-loader npm install css-loader --save 3、安装上面两个之后、再安装vue-awesome-swiper(必须在前两个安装过之后安装) npm
阅读全文
摘要:let routeData = this.$router.resolve({ name: "detail", query: {goodsId:'1111'} }); window.open(routeData.href, '_blank');
阅读全文
摘要:首先需要声明的是:本地请求,不用考虑跨域问题,这适用刚入坑的前端小白看,小白在做自己的项目时,通常都是用自己写的json数据,之后用axios请求过来,渲染到页面上。 1、cnpm install axios --save (在终端安装 上axios,我是用的淘宝镜像安装的) 2、哪个组件使用axi
阅读全文
摘要:课堂笔记: 项目结构分析: 项目入口:index.html(div#app) 全局vue组件:App.vue(template:div#app) 通过相同id的div,index.html与Appvue关联在了一起(具体怎么关联起来的,不需要关心) App.vue中 写入公共部分(tabbar+ro
阅读全文