小程序组件接收一个数组,在生命周期处理数据,页面渲染的还是没处理的数据?

小程序 文章 2020-08-24 18:01 602 0 全屏看文

AI助手支持GPT4.0

小程序组件接收一个数组,在生命周期处理数据,页面渲染的还是没处理的数据?The applet component receives an array and processes the data during the life cycle. Is the page rendered or unprocessed data?

小程序组件接收一个数组,在生命周期处理数据,页面渲染的还是没处理的数据?

怎么让组件生命周期的处理好的数据渲染在组件上,

How to make the processed data of the component life cycle render on the component,

回答:

stop eating:

写个代码片段吧,要不然你在干啥,不要只会说不行

Trafalgar Lu:还是不行啊,我在生命周期attached里将数据处理后,重新赋值,页面循环的还是之前的数据,ready生命周期也一样
微喵网络:

this.setData

Trafalgar Lu:还是不行啊,我在生命周期attached里将数据处理后,重新赋值,页面循环的还是之前的数据,ready生命周期也一样

-EOF-

AI助手支持GPT4.0