使用 ng-repeat,我将如何遍历以下内容:
var messages : [
{text:"Standard Message"},
{text:"Success Message!", type:"success"},
{text:"Alert Message!", type : "alert"},
{text:"secondary message...", type : "secondary"}
]
我试过了:
<p ng-repeat="message in messages">{{message}}</p>
它似乎不起作用,我该怎么做?