javascript - `[$injector:nomod] Module 'google-maps' is not available` -
i'm using angular-google-maps handle google maps @ angular application. this, have add angular-google-maps.js
to project. page works without error, if add script in following way:
<script type="text/javascript" src="http://www.directiv.es/application/html/js/nlaplante/angular-google-maps/angular-google-maps.js"></script>
but not work, if use local copy, this:
<script type="text/javascript" src="js/libs/directiv.es/angular-google-maps.js"></script>
looking @ firebug, see angular-google-maps.js
file loaded, in case, following error occurs:
uncaught error: [$injector:modulerr] failed instantiate module mapsapp due to: error: [$injector:modulerr] failed instantiate module google-maps due to: error: [$injector:nomod] module 'google-maps' not available! either misspelled the...<omitted>...1)
searching web hours did not find reason or solution. maybe have idea or hint, how find reason?
i found solution , write down here case, runs same problem.
in case, downloaded angular-google-maps extension github, extracted zip-file on windows copied file project. result, error occurs: failed instantiate module google-maps due ...
while loading "the same" js file on http works fine. point is: it's not same file!
the solution take file url link , storing local:
maybe during downloading or extracting, zip-file broken. maybe there character problem. whatever.
if open link http://www.directiv.es/application/html/js/nlaplante/angular-google-maps/angular-google-maps.js
in browser, can right-click file , open source in "source-code" editor , save file on disk.
now can copy new created file project folder location: js/libs/directiv.es/angular-google-maps.js
, works fine.....
Comments
Post a Comment