本文介绍了AngularJS:禁用或删除生成的HTML中的ng-scope和ng-binding的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以删除AngularJS生成的HTML中动态添加的ng-scope和ng-binding属性值?

Is there any way to remove ng-scope and ng-binding attribute values which are added dynamically in HTML generated by AngularJS ?

<tr ng-repeat="student in students" ng-class="isGrey[$index]" ng-click="toggleClass($index)" class="ng-scope">
     <td class="ng-binding">1</td>
     <td class="ng-binding">Mahesh</td>
     <td class="ng-binding">Sapkal</td>
</tr>

推荐答案

myApp.config(['$compileProvider', function ($compileProvider) {
    $compileProvider.debugInfoEnabled(false);
}]);

此处的文档: https://docs.angularjs.org/guide/production

这篇关于AngularJS:禁用或删除生成的HTML中的ng-scope和ng-binding的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-28 22:43