2 instances of textAngular on the same page cause $digest error

303 views Asked by At

Does anybody know how to fix it?

Error: [$rootScope:inprog] $digest already in progress http://errors.angularjs.org/1.3.2/$rootScope/inprog?p0=%24digestminErr/<@http://localhost:3030/vendor/angular/angular.js:80:12 beginPhase@http://localhost:3030/vendor/angular/angular.js:14553:1 $RootScopeProvider/this.$get</Scope.prototype.$digest@http://localhost:3030/vendor/angular/angular.js:13996:9 FormGroupController.prototype.update@http://localhost:3030/vendor/ng-form-group/index.js:33:16__bind/<@http://localhost:3030/vendor/ng-form-group/index.js:8:58 $RootScopeProvider/this.$get</Scope.prototype.$digest@http://localhost:3030/vendor/angular/angular.js:14034:34 $RootScopeProvider/this.$get</Scope.prototype.$apply@http://localhost:3030/vendor/angular/angular.js:14304:13 done@http://localhost:3030/vendor/angular/angular.js:9518:36 completeRequest@http://localhost:3030/vendor/angular/angular.js:9703:7 requestLoaded@http://localhost:3030/vendor/angular/angular.js:9646:1 http://localhost:3030/vendor/angular/angular.js Line 11383

angular.module('MyApp', ['textAngular']).controller('MyCtrl', function($scope){
  
})
<link href="http://netdna.bootstrapcdn.com/bootstrap/3.0.3/css/bootstrap.min.css" rel="stylesheet"/>
<link href="http://netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.min.css" rel="stylesheet"/>


<script src="https://cdnjs.cloudflare.com/ajax/libs/angular.js/1.3.2/angular.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/textAngular/1.5.0/textAngular-rangy.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/textAngular/1.5.0/textAngular-sanitize.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/textAngular/1.5.0/textAngular.min.js"></script>

<section ng-app="MyApp">
  <div ng-controller="MyCtrl">
    <div text-angular ng-model="html"></div>
    <div text-angular ng-model="html1"></div>
  </div>
</section>

0

There are 0 answers