- wxs 无法使用 定时函数 ,callMethod 传入回调函数接收为null?
不知道是不是我 写的有问题,官方大大 帮忙 解下惑 https://developers.weixin.qq.com/s/PwHZwsms7Vav pc : mac | 开发者工具:1.02.1907160
2019-08-08 - wxs 编辑器运行可以 真机运行无响应?
wxml 文件代码 <wxs src="list.wxs" module="list_refresh" /> <!-- 选择器 --> <template is="Screen" data="{{...screenData}}" /> <!-- BODY --> <scroll-view id='content' bindtouchstart="touchTest" bindtouchmove="{{list_refresh.touchMove}}" bindtouchend="{{list_refresh.touchEnd}}" scroll-y upper-threshold="-50" lower-threshold='80' scroll-with-animation='true' bindscrolltolower="onReachBottom" class='{{noneScroll}}' hidden='{{hideView}}'> wxs 文件代码 var touchStartX = 0,touchStartY = 0; function touchStart(e,ins){ console.log('touchStart') var touch = e.touches[0] || e.changedTouches[0] touchStartX = touch.pageX touchStartY = touch.pageY console.log([touchStartX,touchStartY]); } function touchMove(e,ins){ console.log('touchMove') var touch = e.touches[0] || e.changedTouches[0] console.log(touch) } function touchEnd(e,ins){ console.log("touchEnd") var touch = e.touches[0] || e.changedTouches[0] console.log(touch) } module.exports = { touchStart:touchStart, touchMove:touchMove, touchEnd:touchEnd } js 文件部分代码 touchTest:function(e){ console.log(e); console.log('test') },
2019-08-07