eric.dummy eric.dummy - 10 months ago 54
AngularJS Question

AngularJS Bootstrap - Error in Console

I'm trying to set up

from AngularJS Bootstrap, however I get an error in console. More on that below.


var app = angular.module('carApp', ['ui-bootstrap']);


app.controller('carCtrl', function($scope, $http, $uibModal) {
$http.get('jobs.json').success(function(data) {
$ = data;

$ = function() {

var modalContent = ${
templateUrl: 'careersTpl.html',
controller : modalContentCtrl,
resolve: {
items: function() {
return $;


<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script src=""></script>
<script src=""></script>
<script src=""></script>
<script src=""></script>
<script src=""></script>
<script src=""></script>
<script src="" integrity="sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa" crossorigin="anonymous"></script>
<link rel="stylesheet" href="" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
<script src="js/app.js"></script>
<script src="js/careersCtrl.js"></script>

<body data-ng-app="carApp">
<div data-ng-controller="carCtrl" class="car-up">
<script type="text/ng-template" id="careersTpl.html">
<div class="modal-header">
<h3>Lorem Ipsum</h3>
<div class="modal-body">

<button class="btn" ng-click="open()">Open</button>

This type of errors is usually displayed, when something is not linked correctly. Error:

Error: [$injector:modulerr]$injector/modulerr?p0=carApp&

Please note that
is on local server and there have been no

Answer Source

The UI-bootstrap module name has a dot, not a hyphen.

var app = angular.module('carApp', ['ui.bootstrap']);