By default, Angular provides a lot of debug information on the DOM that's only necessary for tools like Protractor and Batarang. Angular 1.3 allows you to turn off the debug information to give your app a simple performance boost.

See: https://docs.angularjs.org/api/ng/provider/$compileProvider

More: https://docs.angularjs.org/guide/production#disabling-debug-data

<!DOCTYPE html>
<html ng-app="app">
<head>
<title></title>
<link href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.1/css/bootstrap.min.css" rel="stylesheet">
<script src="//cdnjs.cloudflare.com/ajax/libs/angular.js/1.3.3/angular.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/angular-ui-router/0.2.11/angular-ui-router.js"></script>
<script src="app.js"></script>
</head>
<body>
<script type="text/ng-template" id="templates/home.html">
<note message="Hello"></note>
</script> <ui-view></ui-view> </body>
</html>
angular.module("app", ["ui.router"])

    .config(function config($stateProvider, $compileProvider) {
$stateProvider.state("home", {
url: "",
templateUrl: "templates/home.html"
}) $compileProvider.debugInfoEnabled(false);
}) .directive("note", function note() {
return {
template: "<div>{{ note.message }} {{ note.person }}</div>",
controller: "NoteController as note",
bindToController: true,
scope: {
message: "@"
}
}
}) .controller("NoteController", function NoteController() {
var note = this; note.person = "John";
})

Without debug info:

If you want open the debug info again:

in console:

angular.reloadWithDebugInfo();

[AngularJS] New in Angular 1.3 - Performance Boost with debugInfoEnabled的更多相关文章

  1. [AngularJS] Enable Animations Explicitly For A Performance Boost In AngularJS

    http://www.bennadel.com/blog/2935-enable-animations-explicitly-for-a-performance-boost-in-angularjs. ...

  2. [Angular] Use Angular components in AngularJS applications with Angular Elements

    When migrating AngularJS (v1.x) applications to Angular you have different options. Using Angular El ...

  3. 【js类库AngularJs】解决angular+springmvc的post提交问题

    [js类库AngularJs]解决angular+springmvc的post提交问题 AngularJS诞生于2009年,由Misko Hevery 等人创建,后为Google所收购.是一款优秀的前 ...

  4. [AngularJS] Lazy loading Angular modules with ocLazyLoad

    With the ocLazyLoad you can load AngularJS modules on demand. This is very handy for runtime loading ...

  5. [AngularJS] New in Angular 1.5 ng-animate-swap

    <!DOCTYPE html> <html ng-app="MyApplication"> <head> <link rel=" ...

  6. AngularJS进阶(五)Angular实现下拉菜单多选

    Angular实现下拉菜单多选 写这篇文章时,引用文章地址如下: http://ngmodules.org/modules/angularjs-dropdown-multiselect http:// ...

  7. AngularJS进阶(四)ANGULAR.JS实现下拉菜单单选

    ANGULAR.JS: NG-SELECT AND NG-OPTIONS PS:其实看英文文档比看中文文档更容易理解,前提是你的英语基础还可以.英文文档对于知识点讲述简明扼要,通俗易懂,而有些中文文档 ...

  8. [AngularJS] Using the Angular scope $destroy event and method

    With Angular scopes, you have access to a $destroy event that can be used to watch $scope events. Th ...

  9. [AngularJS] New in Angular 1.3 - bindToController

    If you want to use controllers, instead of a link function, you can use bindToController. <!DOCTY ...

随机推荐

  1. Js原型模式

    function Person(){ } Person.prototype.name = "xd"; Person.prototype.age = 26; Person.proto ...

  2. delphi7 开发布局

    delphi7界面布局(就是各种框框,代码管理器之类的东东)好了的,为什么以打开个新项目或者下次进入开发界面是环境的布局全部变了,如何才能锁定窗口布局? 在菜单栏最右边,有一个按钮save curre ...

  3. C ~ char int 等数据转换问题

    1,char型数字转换为int型 "; printf(]-');//输出结果为3 2,int转化为char (1)字符串转换成数字,用atoi,atol,atof,分别对应的是整型,long ...

  4. asmcmd报错

    在进入asm的命令行时报错: 报错内容如下 [oracle@kel dbs]$ asmcmd asmcmd: command disallowed by current instance type 从 ...

  5. 利用Spring.Net技术打造可切换的分布式缓存读写类

    利用Spring.Net技术打造可切换的Memcached分布式缓存读写类 Memcached是一个高性能的分布式内存对象缓存系统,因为工作在内存,读写速率比数据库高的不是一般的多,和Radis一样具 ...

  6. 多校5 1004 HDU5784 统计锐角三角形数目

    http://acm.hdu.edu.cn/showproblem.php?pid=5784 题意:n个点,找多少个锐角三角形数目 思路:极角排序+two pointers 当前选择的点集要倍增一倍, ...

  7. 读《HTML5与CSS3权威指南(上册)》笔记

    第二章 1.内容类型:“text/html”.DOCTYPE声明:<!DOCTYPE html>.指定字符编码:<meta charset="utf-8"> ...

  8. java集合框架1

    1.综述 所有集合类都位于java.util包下.集合中只能保存对象(保存对象的引用变量).(数组既可以保存基本类型的数据也可以保存对象). 当我们把一个对象放入集合中后,系统会把所有集合元素都当成O ...

  9. 解决A program file was not specified in the launch configuration.问题

        问题描述: 在eclipse 中开发c++或c是比较麻烦的事情,刚刚配置好mingw32和cdt和环境变量后,新建一个hello world的c++项目还是会出现问题.主要是在编译的时候会提示 ...

  10. Android实例-手机震动(XE8+小米2)

    相关资料:http://blog.csdn.net/laorenshen/article/details/41148843 结果: 1.打开Vibrate权限为True. 2.规律震动我没感觉出来,有 ...