日韩av黄I国产麻豆传媒I国产91av视频在线观看I日韩一区二区三区在线看I美女国产在线I麻豆视频国产在线观看I成人黄色短片

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 >

VUE iscroll(银联二维码,浩哥页面用过)

發布時間:2025/4/14 36 豆豆
生活随笔 收集整理的這篇文章主要介紹了 VUE iscroll(银联二维码,浩哥页面用过) 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

基本使用方法:

$ npm i vue-iscroll-view --save-dev $ npm i iscroll --save-dev

  

import IScrollView from 'vue-iscroll-view'/* Using these kinds of IScroll class for different cases. */ import IScroll from 'iscroll' // import IScroll from 'iscroll/build/iscroll-infinite.js // import IScroll from 'iscroll/build/iscroll-probe.js // import IScroll from 'iscroll/build/iscroll-view.js // import IScroll from 'iscroll/build/iscroll-zoom.js // import IScroll from 'iscroll/build/iscroll-lite.jsVue.use(IScrollView, IScroll)

  

<template><iscroll-view class="scroll-view">Your contents</iscroll-view> </tempalte><style> .scroll-view {/* -- Attention: This line is extremely important in chrome 55+! -- */touch-action: none;/* -- Attention-- */position: fixed;top: 0;bottom: 0;left: 0;right: 0;overflow: hidden; } </style>

  

手機上不能點擊的處理辦法

<template><iscroll-view :options="{preventDefault: false}">Your contents</iscroll-view> </tempalte>

  

滾動事件

<template><iscroll-view @scrollStart="log">Your contents</iscroll-view> </tempalte><script> export default {methods: {log (iscroll) {console.log(iscroll)}} } </script>

  

返回頂部

<template><div><iscroll-view ref="iscroll">Your contents</iscroll-view><button @click="scrollToTop">Scroll To Top</button></div> </tempalte><script> export default {methods: {scrollToTop () {const iscroll = this.$refs.iscrolliscroll.scrollTo(0, 0, 100)iscroll.refresh()}} } </script>

  

上拉下拉事件

<template><iscroll-view @pullUp="load" @pullDown="refresh">Your contents</iscroll-view> </tempalte><script> export default {methods: {refresh (iscroll) {// Refresh current data},load (iscroll) {// Load new data}} } </script>

  

轉自:http://blog.csdn.net/weixin_38788947/article/details/77447785?fps=1&locationNum=3

轉載于:https://www.cnblogs.com/ourLifes/p/8386744.html

總結

以上是生活随笔為你收集整理的VUE iscroll(银联二维码,浩哥页面用过)的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。