title: Angularjs StreamHelperController is not a function
body: <p>I do understand why angular throws this error but i didn't find a solution that solves my case.</p>
  
  <p>When angular encounter with ng-controller attribute, it tries to find injected controller named as the attribute value. </p>
  
  <p>For example for my case:
  
  Angular tries to find StreamHelperController in the injected controller list, when it doesn not find it, it throws </p>
  
  <blockquote>
    <p>"StreamHelperController is not a function"</p>
  </blockquote>
  
  <p>.</p>
  
  <p>Known Solution: Injecting controller before loading view layer.</p>
  
  <p>Controller:</p>
  
  <pre><code>var app = angular.module('myapp');
   app.controller('StreamHelperController', ['$scope', function ($scope) {}]);
  </code></pre>
  
  <p>View:</p>
  
  <pre><code>&lt;div ng-controller="StreamHelperController "&gt;
  </code></pre>
  
  <p>But the problem occurs when i load view before controller class. And this is my case. So how can i manage and solve this problem ?</p>
  
  <p>ENV:
  Angularjs 1.5.8</p>