Skip to content
This repository was archived by the owner on May 29, 2019. It is now read-only.

$UIModal TypeError: ctrlInstantiate is not a function - 1.7.1 Bower Angular #6708

Closed
egamboa opened this issue Jun 12, 2018 · 14 comments
Closed

Comments

@egamboa
Copy link

egamboa commented Jun 12, 2018

There is no later option:
ctrlInstantiate = $controller(modalOptions.controller, ctrlLocals, true, modalOptions.controllerAs);

https://github.com/angular/bower-angular

1.7.1 has no later :(

PLEASE READ

As per the README, this project is no longer being maintained. Any issues entered will remain uninvestigated and unresolved.

We thank you for your contributions over the years. This library would not have been successful without them.

@jelmerjellema
Copy link

That's what you get when you use a private api.

I see there is no later in the 1.7.1 branch, but is does seem to appear in the master-snapshot branche (https://github.com/angular/angular.js/blob/master/src/ng/controller.js#L84). Would this mean there will be a fix in AngularJS soon? I wouldn't know...

@jelmerjellema
Copy link

Filed an issue with angularjs angular/angular.js#16598

@simonguertin
Copy link

Hi, I am not sure what happened in my project. This is happening to me too. Can I just force an old version to fix the issue ? But what ?

@jelmerjellema
Copy link

Hi, Angularjs will fix this in 1.7.2 (angular/angular.js#16594). For now I just fixed "angular": "1.7.0" in my bower.json en did a bower install.

@egamboa
Copy link
Author

egamboa commented Jun 12, 2018

Correct, you need to go back. I have a log for each test I run so I was able to get a list of all previous version, this was caused by the release of angular 1.7.1

@simonguertin
Copy link

Thanks, I am trying in bower.json:
"dependencies": {
"angular-bootstrap": "^2.2.0",
"angular-lazy-img": "^1.1.0",
"angular": "1.7.0",
...

"resolutions": {
"angular-bootstrap": "^2.2.0",
"angular": "1.7.0"
}

but something keeps installing angular 1.7.1

@jelmerjellema
Copy link

Yeah, for example angular-bootstrap itself asks for angular ^1.4.0, which resolves to 1.7.1. I removed the resolution for angular, and then did

bower install --save angular
!1

Bower asks for which resolution to use, and you take the one explicitly mentioned. The exclamation mark says "save this". Bower.json looks the same as above afterwards, but then angular 1.7.0 is installed. If this does not help, just remove bower_components/angular and do bower install.

@egamboa
Copy link
Author

egamboa commented Jun 12, 2018

Try using angular-bootstrap: 1.3.3 That is working for me.

@simonguertin
Copy link

thanks a lot! I got it to work now.

@egamboa
Copy link
Author

egamboa commented Jun 12, 2018

@jelmerjellema what will be the latest version that works with 1.7.0? I guess is better than having an old like our project.

@jelmerjellema
Copy link

What do you mean? The newest version of ui-bootstrap works with 1.7.0

@egamboa
Copy link
Author

egamboa commented Jun 12, 2018

TY, that's it.

@egamboa egamboa closed this as completed Jun 12, 2018
@jelmerjellema
Copy link

Angular 1.7.2 has been released now

@imrvelj
Copy link

imrvelj commented Jun 13, 2018

Can confirm - works with 1.7.2

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants