I am using ngMateril for custom dialog. But I am getting error as Error: [$injector:modulerr]. I am not able to figure out the error. Any help would be appreciated.
External scripts in my HTML code
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js"></script>
<script src="//ajax.googleapis.com/ajax/libs/angularjs/1.4.7/angular.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/angular-ui-router/0.2.15/angular-ui-router.min.js"></script>
<script src="//ajax.googleapis.com/ajax/libs/angular_material/1.0.0/angular-material.min.js"></script>
(function () {
'use strict';
angular
.module('app', ['ui.router'],['ngMaterial'])
.config(config)
.run(run);
function config($stateProvider, $urlRouterProvider) {
// default route
$urlRouterProvider.otherwise("/");
$stateProvider
.state('home', {
url: '/',
templateUrl: 'home/index.html',
controller: 'Home.IndexController',
controllerAs: 'vm',
data: { activeTab: 'home' }
})
.state('account', {
url: '/account',
templateUrl: 'account/index.html',
controller: 'Account.IndexController',
controllerAs: 'vm',
data: { activeTab: 'account' }
});
}
})();
You need to configure your module slightly differently:
.module('app', ['ui.router', 'ngMaterial'])