ui-codemirror icon indicating copy to clipboard operation
ui-codemirror copied to clipboard

[RFR] Fix Strict DI issues and remove ngAnnotate

Open jpetitcolas opened this issue 7 years ago • 5 comments

This PR aims to solve an issue when importing this module in a Strict Dependency Injection environment. Indeed, using current version, installed with npm, we get the following Angular error:

Error: [$injector:strictdi] http://errors.angularjs.org/1.4.12/$injector/strictdi?p0=uiCodemirrorDirective

Bower version is not impacted as ng-annotate plugin seems to be used in this case.

As source file is already compatible with strict DI, I also removed the obsolete ng-annotate plugin.

jpetitcolas avatar Sep 13 '16 09:09 jpetitcolas

Fixes #106.

jpetitcolas avatar Sep 13 '16 09:09 jpetitcolas

Not sure why removing ng-annotate is the solution here. I figure it should work with ng-annotate as expected in npm as long as the main file points to the dist version. #138 Attempts to make the same change.

Also, why aren't these PRs reviewed? Looks like this hasn't been touched for a year.

genu avatar May 09 '17 12:05 genu

@genu: the main fix is here.

Removing ng-annotate has been done because it is not required anymore, as code is compatible with strict DI. But that's a side-effect of the fix.

jpetitcolas avatar May 16 '17 08:05 jpetitcolas

What is the status of this PR. It has been almost a year and this fix is necessary for us. Let me know if there is anything that needs to be done to allow it to get merged in.

postama avatar Mar 19 '18 16:03 postama

Same here. We got a production project using my fork as a dependency. That's not really comfortable. :)

jpetitcolas avatar Mar 19 '18 17:03 jpetitcolas