1、问题背景
AngularJS利用自带的指令,设计出无序列表
2、实现源码
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>AngularJS之无序列表</title>
<script type="text/javascript" src="../js/angular.min.js" ></script>
<script>
var app = angular.module("ulApp",[]);
app.controller("ulCon",function($scope){
$scope.season = [
{times:"春季"},
{times:"夏季"},
{times:"秋季"},
{times:"冬季"}
];
});
</script>
</head>
<body>
<div ng-app="ulApp" ng-controller="ulCon">
<ul>
<li ng-repeat="s in season">
{{s.times}}
</li>
</ul>
</div>
</body>
</html>
3、问题说明
ul是无序列表