wxml绑定class的getter渲染不出来
如题 及 代码片段
class Test{ constructor(){ this .x = '1' ; } get y(){ return '2' ; } } Page({ data: { test : new Test() }, onLoad: function () { } }) |
< view class = "intro" >wxml绑定class的getter显示不出来</ view > < view >下面应该显示1和2</ view > < view >{{test.x}}</ view > < view >{{test.y}}</ view > |