Announcement: Tencent Cloud Mini Program Platform Renamed to Tencent Cloud Super App as a Service on January 2, 2025
Console Updates
Android SDK Updates
iOS SDK Updates
Flutter SDK Updates
IDE Updates
Base Library Updates
<view> {{ message }} </view>
Page({data: {message: 'Hello MINA!'}})
<view id="item-{{id}}"> </view>
Page({data: {id: 0}})
<view wx:if="{{condition}}"> </view>
Page({data: {condition: true}})
<checkbox checked="{{false}}"> </checkbox>
<view hidden="{{flag ? true : false}}"> Hidden </view>
<view> {{a + b}} + {{c}} + d </view>
Page({data: {a: 1,b: 2,c: 3}})
<view wx:if="{{length > 5}}"> </view>
<view>{{"hello" + name}}</view>
Page({data:{name: 'MINA'}})
<view>{{object.key}} {{array[0]}}</view>
Page({data: {object: {key: 'Hello '},array: ['MINA']}})
<view wx:for="{{[zero, 1, 2, 3, 4]}}"> {{item}} </view>
Page({data: {zero: 0}})
<template is="objectCombine" data="{{for: a, bar: b}}"></template>
Page({data: {a: 1,b: 2}})
<template is="objectCombine" data="{{...obj1, ...obj2, e: 5}}"></template>
Page({data: {obj1: {a: 1,b: 2},obj2: {c: 3,d: 4}}})
<template is="objectCombine" data="{{foo, bar}}"></template>
Page({data: {foo: 'my-foo',bar: 'my-bar'}})
<template is="objectCombine" data="{{...obj1, ...obj2, a, c: 6}}"></template>
Page({data: {obj1: {a: 1,b: 2},obj2: {b: 3,c: 4},a: 5}})
<view wx:for="{{[1,2,3]}} ">{{item}}</view>
<view wx:for="{{[1,2,3] + ' '}}">{{item}}</view>
Was this page helpful?
You can also Contact sales or Submit a Ticket for help.
Help us improve! Rate your documentation experience in 5 mins.
Feedback