-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Modal unknown provider #2247
Comments
Please surround your different code blocks with triple ticks (```). Your code is quite hard to read as-is. |
@Awk34 sorry about that, I have updated |
Can you provide a full stack trace as well? |
Can you post what's in modal.service? You're expecting the import to provide you a module name but I'm not sure that's what you're importing |
|
Your specific issue seems to be case. In your app.js you're importing with lowercase 'm' but in your controller your using it as 'M'. Try fixing it to a capital 'M' when importing and in your injection. With that being said; i am also having trouble with this Modal. When i call $uibModal directly from my controller it works the way a Modal should. But not via this service. |
Ive created a PR that fixes this issue. #2256 The problem lies at the export of the factory. Change
to
|
Thanks @Azayzel ! I really appreciate it! Got my first modal to pop up today using the Modal service. Next stop is injecting the controller scope i'm calling the modal from into the modal itself. |
I'm seeing the same issue - angular.js:14525 Error: [$injector:strictdi] Modal is not using explicit annotation and cannot be invoked in strict mode. Any solution? |
Usually that happens when you forget an nginject annotation
On Apr 23, 2017 11:15 PM, "Derek Carr" <[email protected]> wrote:
I'm seeing the same issue - angular.js:14525 Error: [$injector:strictdi]
Modal is not using explicit annotation and cannot be invoked in strict mode.
Any solution?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#2247 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ADEBQwQISUfKiYq1nGrqXp4UtRt4xRX2ks5rzBPEgaJpZM4KB7BM>
.
|
#2203 Fixed the issue. |
I cannot figure out why the Modal service injection is not working. I have added it as a dependency to the app.js and as well have added the dependency to the controller which I would like to use it from. Very desperate to get this working and appreciate anyone who can help me figure this out.
app.js
controller trying to use the Modal
EDIT: if you;d like to see the project itself you can find it here: https://camden-first-hopeworks.c9users.io:8081/
The text was updated successfully, but these errors were encountered: