我也遇到了和你一样的问题,我使用 angular-1.4.3 版本解决了这个问题,这是我解决问题的过程。当我尝试运行演示时,我试图从网络演示地址运行指令“nginclude”,像你一样在firefox控制台中弹出错误,但是当我将版本更改为角度的1.4.3时,这一切解决。顺便说一下,你可以从1.4.3下载版本
.js
var APP = angular.module('app', ['ngAnimate'])
APP.controller('ctrl', ['$scope', function($scope) {
$scope.templates =
[{name: 'template1.html',url:'template1.html'},
{name: 'template2.html',url:'template2.html'}];
$scope.template = $scope.templates[0];}]);
.html
<!DOCTYPE html>
<html ng-app="app">
<head>
<meta Content-Type="html/text;charset=UTF-8">
<link rel="stylesheet" type="text/css" href="css/animation.css">
<title>ngInclude demo</title>
</head>
<body>
<div ng-controller="ctrl">
<select ng-model="template" ng-options="t.name for t in templates">
<option value="">(blank)</option>
</select>
url of the template: <code>{{template.url}}</code>
<hr/>
<div class="slide-animate-container">
<div class="slide-animate" ng-include="template.url"></div>
</div>
</div>
</body>
<script src="js/angular.js"></script>
<script src="js/ngInclude.js"></script>
<script src="js/angular-animate.js"></script>
</html>
谢谢你。