This repository has been archived by the owner on May 25, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 194
Unknown Provider error when using minified ui-codemirror.js #110
Comments
👍 |
@Patrix2001 would you please make a pull request? |
It is really helpful! Thank you! |
Still not fixed (?) |
crittermike
added a commit
to crittermike/ui-codemirror
that referenced
this issue
Dec 2, 2017
crittermike
added a commit
to crittermike/shortkeys
that referenced
this issue
Dec 2, 2017
FWIW, I forked the repo and added the fix mentioned in this issue. See above referenced commits for how to point to the fork instead of the official repo, if you'd like. |
@mikecrittenden you saved my day. |
@daohodac I don't think so - the official repo hasn't had a commit in almost 3 years. |
Having the same problem |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hi,
When using the ui-codemirror directive in production (bundled and minified using ASP.NET MVC) I get the following error:
Unknown provider: nProvider <- n <- uiCodemirrorDirective
This is caused by the dependency uiCodemirrorDirective (on line 13 of ui-codemirror.js) is minified to the character 'n' and of course AngularJS does not know what to inject in.
The fix is very simple.
on line 8 of ui-codemirror.js simply provide an array which states the required dependencies as strings:
.directive('uiCodemirror', ['$timeout', 'uiCodemirrorConfig', uiCodemirrorDirective]);
Cheers
The text was updated successfully, but these errors were encountered: