AngularJs issues


AngularJS is a nice MVC based javascript framework, developed by google. One of the important functionality I liked about this framework is dependency injection. In this post I will be posting all technical issues faced during development process

Today I came across an issue when trying to open a modal window from another modal window. The error was

Unknown provider: $uibModalInstanceProvider <- $uibModalInstance

The error occurs if the template of the modal contains ng-controller. The problem was that you were specifying a (or double) controller(s) in 2 places- when opening a modal and inside a template – this is not needed. Remove ng-controller from a template and things will work as expected.