0

I'm trying to implement a mobile app using mobile angular ui with a firebase data base.

But I can't include firebase without getting this error:

Uncaught ReferenceError: angular is not defined
at angularfire.min.js:1
at angularfire.min.js:1

I don't understand why this happens, because I include angular before the other dependencies? (not the "normal" angular but mobile-angular-ui)

<!DOCTYPE html>
<html>

<head>
  <meta charset="utf-8" />
  <title>(...)</title>

  <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
  <meta name="apple-mobile-web-app-capable" content="yes" />
  <meta name="viewport" content="user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimal-ui" />
  <meta name="apple-mobile-web-app-status-bar-style" content="yes" />
  <link rel="stylesheet" href="css/app.min.css" />
  <link rel="stylesheet" href="css/responsive.min.css" />

  <!-- Angular -->
  <script src="/dist/js/mobile-angular-ui.min.js"></script>
  <!-- Required to use $touch, $swipe, $drag and $translate services -->
  <script src="/dist/js/mobile-angular-ui.gestures.min.js"></script>

  <!-- Firebase -->
  <script src="https://www.gstatic.com/firebasejs/3.6.6/firebase.js"></script>

  <!-- AngularFire -->
  <script src="https://cdn.firebase.com/libs/angularfire/2.3.0/angularfire.min.js"></script>
  <script src="js/app.min.js"></script>
  <script src="js/app.js"></script>
</head>

<body ng-app="(...)" ng-controller="MainController">
ReyAnthonyRenacia
  • 17,219
  • 5
  • 37
  • 56
gima
  • 52
  • 7

2 Answers2

1

From what the Mobile Angular UI Docs say, you have to include the regular angular.js file as well right above it.

Terrtiary
  • 191
  • 1
  • 14
0

Doesn't angular-ui depend on angular?

I see the script for angular-ui, but not the one for angular itself.

theGleep
  • 1,179
  • 8
  • 14