Angular Uncaught Object
angularjs, javascript
Solution
I had the same error; if you activate Chrome to pause on exceptions, you'll be able to have more detailed error information
Problem
I'm new to Angular so i'm still getting my head around how it works. I've stumbled into a problem however (quite early on...) and the below code is giving me "Uncaught Object" in the console and breaks Angular. The .config section is the culprit, if I remove it, the page loads fine. I'm not entirely sure how the error is being caused because to me, everything looks fine? ``` var app = angular.module('app', ['ngRoute']) .config(['$routeProvider', '$locationProvider', function ($routeProvider, $locationProvider) { $routeProvider .when('/dashboard', { templateUrl: '/app/views/admin.html', controller: 'DashboardController' }) .otherwise('/', { redirectTo: '/' }) $locationProvider.html5mode(true); }]) .controller('DashboardController', ['$scope', function ($scope, Security) { $scope.security = Security; }]) ```