angular / angular-hint

run-time hinting for AngularJS applications
362 stars 45 forks source link

AngularHint triggers its own warnings #52

Open sjelin opened 9 years ago

sjelin commented 9 years ago

I created a very simple angular app

<!DOCTYPE html>
<html ng-app ng-hint>
  <head>
    <meta charset="utf-8">
    <title>Angular.js Example</title>
    <script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.26/angular.min.js"></script>
        <script src="ngHint.js"></script>
  </head>
  <body>
    First name:<input ng-model="firstName" type="text"/>
    <br>
    Last name:<input ng-model="lastName" type="text"/>
    <br>
    Hello {{firstName}} {{lastName}}
  </body>
</html>

This triggered two warnings in Angular Hint:

Angular Hint: Modules ngHint.js:119
    Warning ngHint.js:136
        Module "ngHintScopes" was created but never loaded. ngHint.js:138
Angular Hint: Controllers ngHint.js:119
    Warning ngHint.js:136
        It is against Angular best practices to instantiate a controller on the window. This behavior is deprecated in Angular 1.3.0 ngHint.js:138

Clearly none of this is my app's fault. In particular, I was definitely not the one who created ngHintScopes, and further it really should be loaded.