我尝试使用Winjs.ui.repeater动态地将数据绑定到pivotItem中,但调试器抛出错误并显示base.js,任何人都可以帮助我。
<section class="page-section" aria-label="Main content" role="main">
<div>
<div data-win-control="WinJS.UI.Pivot">
<div data-win-control="WinJS.UI.PivotItem" data-win-options="{'header':'AJJ-MAS'}">
<div data-win-control="WinJS.UI.Repeater" data-win-options="{data: AjjMsb.data}">
<section>
<label data-win-bind="{innerText:trainnumber}"></label>
<p data-win-bind="{innerText:starttime}"></p>
<p data-win-bind="{innerText:endtime}"></p>
</section>
</div>
</div>
<div data-win-control="WinJS.UI.PivotItem" data-win-options="{'header':'AJJ-MSB'}">
</div>
</div>
</div>
</section>
data-win-bind属性不需要大括号。如果这解决了你的问题,请告诉我!