什么是生产和发展模式之间angular2差异 [英] What is diff between production and development mode in angular2

查看:785
本文介绍了什么是生产和发展模式之间angular2差异的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的工作angular2应用程序,由于某种原因,我必须跑我在生产模式下的应用程序。

I am working on angular2 app, for some reason i have to run my app in production mode.

什么是这些模式之间的差异。

what is the diff between those mode.

推荐答案

在开发模式下,变化检测后第一次运行做了第二次立即运行,如果任何绑定值的第一和第二轮之间变化产生一个错误。这有助于找出错误的地方检查值有副作用或字段或函数不返回后续调用相同的值这有损Angulars变化检测。

In development mode, change detection does a 2nd run immediately after the first run and produces an error if any bound value has changed between the first and the second run. This helps to locate bugs where checking values has side-effects or fields or functions doesn't return the same value on subsequent calls which undermines Angulars change detection.

这篇关于什么是生产和发展模式之间angular2差异的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆