logbon72 / angular-material-datetimepicker

Datepicker for Angular Material, mimick's Android's date time picker
https://logbon72.github.io/angular-material-datetimepicker
MIT License
169 stars 123 forks source link

Error injecting to module #97

Closed najiJazzar closed 7 years ago

najiJazzar commented 7 years ago

when I add 'ngMaterialDatePicker' to module like this :

angular.module('myApp', [ ... , 'ngMaterialDatePicker' ... ])

the following error occurs :

Uncaught Error: [$injector:modulerr] Failed to instantiate module myApp due to:
Error: [$injector:modulerr] Failed to instantiate module ngMaterialDatePicker due to:
Error: [$injector:nomod] Module 'ngMaterialDatePicker' is not available! You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second argument.
http://errors.angularjs.org/1.6.2/$injector/nomod?p0=ngMaterialDatePicker 

at http://localhost:9000/bower_components/angular/angular.js:68:12
    at http://localhost:9000/bower_components/angular/angular.js:2187:17
    at ensure (http://localhost:9000/bower_components/angular/angular.js:2111:38)
    at module (http://localhost:9000/bower_components/angular/angular.js:2185:14)
    at http://localhost:9000/bower_components/angular/angular.js:4756:22
    at forEach (http://localhost:9000/bower_components/angular/angular.js:357:20)
    at loadModules (http://localhost:9000/bower_components/angular/angular.js:4740:5)
    at http://localhost:9000/bower_components/angular/angular.js:4757:40
    at forEach (http://localhost:9000/bower_components/angular/angular.js:357:20)
    at loadModules (http://localhost:9000/bower_components/angular/angular.js:4740:5)

I use angular 1.6.2 any help ??

hexadecy commented 7 years ago

And your index file? There is no unminified files in dist.

najiJazzar commented 7 years ago

I checked my index file and noticed that the unminified files weren't loaded I've installed the package using bower bower install angular-material-datetimepicker --save

And everything worked fine, thanks for your note. :+1: