同一页面上的2个textAngular实例导致$ digest错误

时间:2016-01-25 13:22:15

标签: angularjs textangular

有人知道如何解决它吗?

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

&#13;
&#13;
angular.module('MyApp', ['textAngular']).controller('MyCtrl', function($scope){
  
})
&#13;
<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>
&#13;
&#13;
&#13;

0 个答案:

没有答案