Ciprian Turcu
Ciprian Turcu

Reputation: 1233

mdThemingProvider Angular Material Error

I can't figure out why $mdThemingProvider crashes.

var app = angular.module( 'aBMain',['ngMaterial']);
  console.log('3');

app.config(function($mdThemingProvider){
  console.log('4');

  $mdThemingProvider.theme('default')
    .primaryPalette('pink')
    .accentPalette('orange');

});

Codepen : http://codepen.io/turcuciprian/pen/mPwBOm check out the console. It's supposed to output 4, why does it hang here? (with an error. What am I missing?

Upvotes: 1

Views: 156

Answers (1)

Lex
Lex

Reputation: 7194

You are missing two references:

  1. angular-animate.js (or angular-animate.min.js) CDN
  2. angular-aria.js (or angular-aria.min.js) CDN

Always debug with the non-minified versions. As soon as I changed your Codepen to use the non-minified versions the exact reason for the error was spelled out in the console.

Upvotes: 1

Related Questions