JSFiddle - React, Tailwind, and code Playground
by yokano
HTML
<div ng-app>
<div ng-controller="Controller">
<p>リストの中身を表示</p>
<ul>
<li ng-repeat="name in names">
name[{{$index}}]:{{name}}
</li>
</ul>
<p>リストの要素がオブジェクトの場合</p>
<ul>
<li ng-repeat="person in persons">
{{person.name}} is {{person.sex}}
</li>
</ul>
</div>
</div>
JavaScript
var Controller = function($scope) {
$scope.names = [
'tanaka', 'suzuki', 'sato'
];
$scope.persons = [
{name: 'tanaka', sex: 'man'},
{name: 'sato', sex: 'woman'},
{name: 'suzuki', sex: 'woman'}
];
};