angular-ui / bootstrap

PLEASE READ THE PROJECT STATUS BELOW. Native AngularJS (Angular) directives for Bootstrap. Smaller footprint (20kB gzipped), no 3rd party JS dependencies (jQuery, bootstrap JS) required. Please read the README.md file before submitting an issue!
http://angular-ui.github.io/bootstrap/
MIT License
14.29k stars 6.73k forks source link

Modal controllerAs with default value "$ctrl" #6434

Open bastienmoulia opened 7 years ago

bastienmoulia commented 7 years ago

Bug description:

Not a bug but a nice thing to have to be consistant with the angular way. When a modal is open with a controller and no controllerAs attribute the value of controllerAs should have $ctrl as default value like a component controller: https://docs.angularjs.org/guide/component#comparison-between-directive-definition-and-component-definition

Link to minimally-working plunker that reproduces the issue:

https://plnkr.co/edit/BoWfAtkzL8nGl4610PuT?p=preview

Version of Angular, UIBS, and Bootstrap

Angular: 1.6.1

UIBS: 2.4.0

Bootstrap: 3.3.7