您好我正在关注此脚本https://github.com/rpocklin/angular-scroll-animate我在此链接中执行了所有操作,但我的数据未显示,并且我在控制台中出现错误:angular未定义 有什么想法吗?
HTML
<!DOCTYPE html>
<html ng-app="portfolios">
<head>
<base href="/">
<title> - CV</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<link rel="icon" href="assets/favicon.ico" type="image/x-icon">
<!-- build:css app.css -->
<!-- bower:css -->
<!-- endinject -->
<script src="bower_components/angular-scroll-animate/dist/angular-scroll-animate.js"></script>
<link rel="stylesheet" href="styles/css/app.css">
<link rel="stylesheet" href="styles/css/animate.css">
<!-- endbuild -->
</head>
<body>
<div ng-view></div>
<!-- build:js app.js -->
<!-- bower:js -->
<script src="bower_components/angular/angular.js"></script>
<script src="bower_components/angular-route/angular-route.js"></script>
<script src="bower_components/angular-scroll-animate/dist/angular-scroll-animate.js"></script>
<!-- endinject -->
<!-- inject:js -->
<script src="views/home/home.controller.js"></script>
<script src="views/home/home.js"></script>
<script src="app.js"></script>
<!-- endinject -->
<!-- endbuild -->
<script src="http://localhost:35729/livereload.js?snipver=1"></script>
</body>
</html>
答案 0 :(得分:0)
正确调用脚本文件:
<head>
<base href="/">
<title> - CV</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<link rel="icon" href="assets/favicon.ico" type="image/x-icon">
<!-- build:css app.css -->
<!-- bower:css -->
<!-- bower:js -->
<script src="bower_components/angular/angular.js"></script>
<script src="bower_components/angular-route/angular-route.js"></script>
<script src="bower_components/angular-scroll-animate/dist/angular-scroll-animate.js"></script>
<!-- endinject -->
<!-- inject:js -->
<script src="views/home/home.controller.js"></script>
<script src="views/home/home.js"></script>
<script src="app.js"></script>
<!-- endinject -->
<link rel="stylesheet" href="styles/css/app.css">
<link rel="stylesheet" href="styles/css/animate.css">
<!-- endbuild -->
</head>