微信小程序开发之页面数据绑定

js:Page(

{

data:{

parmer:"",             //字符串参数

userinfo:{
      userphone:"",
      headimage:"../../../../../../image/个人中心/个人中心_07.png",
      username:"半世浮沉"
    }                       //对象参数

}

})

wxml:

<image  class="imagestyle" src="{{userinfo.headimage}}"></image>

<text class="info-motto">{{userinfo.username}}</text>

<view class=""backstyle>{{parmer}}</view>

原文地址:https://www.cnblogs.com/min-min-min/p/6869524.html