在button的tap事件中执行this.animate()报错:
RangeError: Maximum call stack size exceeded
animate
Page({
animate() {
this.animate('.v', [{opacity: 0}, {opacity: 1}], 3000, () => {console.log('ok')})
}
})
WAServiceMainContext.js?t=wechat&s=1678821934938&v=2.30.2:1 RangeError: Maximum call stack size exceeded
at _a.animate (index.js:3)
at _a.animate (index.js:3)
at _a.animate (index.js:3)
at _a.animate (index.js:3)
at _a.animate (index.js:3)
at _a.animate (index.js:3)
at _a.animate (index.js:3)
at _a.animate (index.js:3)
at _a.animate (index.js:3)
at _a.animate (index.js:3)(env: macOS,mp,1.06.2301160; lib: 2.30.2)
死循环了,在方法内部调用自己。。。这写法有点骚啊