- content: WxParse.wxParse('article', 'html', data.content, that, 5)
本身wxParse已经把你的data.content赋值给了article,没有返回值,也就是造成conten被setData一个空值了,就会出现如上报错!
修复方式如下:
- WxParse.wxParse('article', 'html', content.content, that, 5)//新增
- that.setData({
- //content:WxParse.wxParse('article', 'html', content.content, that, 5)//注释或者直接删掉
- })