'use strict';

// Directive for using http://www.jacklmoore.com/autosize/
angular.module('Teem')
  .directive('textfit',[
  '$timeout',
  function($timeout) {
    return {
      link: function(scope, element, attrs) {
        textFit(element);

        scope.$watch(attrs.ngBind, function() {
         $timeout(() => {
           textFit(element);
         }, 1000); // There should be a better way to do this :-(
       });
      }
    };
  }]);

'use strict';

// Directive for using http://www.jacklmoore.com/autosize/
angular.module('Teem')
  .directive('textfit',[
  '$timeout',
  function($timeout) {
    return {
      link: function(scope, element, attrs) {
        scope.$watch(attrs.ngBind, function() {
         $timeout(() => {
           textFit(element);
         }, 1000); // There should be a better way to do this :-(
       });
      }
    };
  }]);

Remove first call to textFit
Remove first call to textFit
