title: Can I link an external javascript file to an AngularJS controller?
body: <p>This may be a dumb question. I know AngularJS controllers use javascript code to keep the application logic outside of the view. But I was wondering if I could link an external javascript file to a controller so it didn't have to be so long.</p>
  
  <p>If it is possible would you also share the syntax of how I would do this. Something like:</p>
  
  <pre><code>app.controller('demoCtrl', ['$scope', function ($scope) {
      $scope.msgtxt='Hello World';
      src=somejavascriptfile.js;
  }]);
  </code></pre>