html52.com
我爱小程序-开发者交流社区

请教关于setData执行时间问题?

问题是这样的,相同的数据结构setData,在两个文件里面执行效率不一样,请问具体原因是什么?

具体输出是这样的

文件一执行用时2秒,造成在前端渲染的时候,有很明显的延时

(3) [{…}, {…}, {…}]

file1.js? [sm]:437 Sat Mar 07 2020 21:33:54 GMT+0800 (中国标准时间)

file1.js? [sm]:438 {swiperList: Array(3), greenNum: 1, redNum: 0}

file1.js? [sm]:629 autoplay

file1.js? [sm]:450 Sat Mar 07 2020 21:33:56 GMT+0800 (中国标准时间)

file1.js? [sm]:636 pageChange


文件二用时如下:

(3) [{…}, {…}, {…}]

file2.js? [sm]:460 Sat Mar 07 2020 21:35:47 GMT+0800 (中国标准时间)

file2.js? [sm]:461 {swiperList: Array(3), greenNum: 2, redNum: 0}

file2.js? [sm]:660 autoplay

file2.js? [sm]:474 Sat Mar 07 2020 21:35:47 GMT+0800 (中国标准时间)

file2.js? [sm]:667 pageChange

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

真正的个人免签约支付接口

云免签H5支付