angular - 将 OnPush 设置为 nrwl-nx 中所有应用程序的默认值
问题描述
有没有办法让所有组件都使用 OnPush 生成?
如同:ng config schematics.@schematics/angular.component.changeDetection OnPush
解决方案
找到了我的问题的解决方案:)
只需添加
"@schematics/angular:component": {
"style": "scss",
"changeDetection": "OnPush"
}
到你workspace.json
的文件最后"schematics": {}
:)
推荐阅读
- java - 由于其插件,所有 xml 文件的 Eclipse 错误
- php - 如果事务中发生错误,对表的 id 索引有影响吗?
- php - 如何禁用在 Google App Engine 容器上预安装和启用的一些 php 扩展
- python - 未在 python 中显示 Choropleth 地图,没有错误返回
- google-api - YouTube 数据 API 每日配额减少到 0
- java - Eclipse 中奇怪的 Java Web 应用程序
- html - 如何在 flexbox 中居中文本?
- date - 如何使用 d3 .js 散点图在 1900 年之前的 x 轴上呈现日期
- nativescript - Webpack 编译,找不到本地模块:错误:无法解析
- angular - firebase、angular(7) 和 rxjs