Alan Agius 04274afc15
fix(@angular-devkit/build-angular): set public class fields as properties (#24849)
* fix(@angular-devkit/build-angular): set public class fields as properties

Configure Babel to use `setPublicClassFields: true`. As when shipping Angular packages without `"useDefineForClassFields": false` will increase the bundle size of an ng-new app
by ~2Kb when `useDefineForClassFields`  is not false. due to the additional `_defineProperty`, which will be added on every class property.

See: https://babeljs.io/docs/babel-plugin-proposal-class-properties

* fixup! fix(@angular-devkit/build-angular): set public class fields as properties

Co-authored-by: Charles <19598772+clydin@users.noreply.github.com>

---------

Co-authored-by: Charles <19598772+clydin@users.noreply.github.com>
2023-03-14 07:37:57 +00:00
..
2023-01-03 14:51:42 +00:00

@angular-devkit/build-angular

This package contains Architect builders used to build and test Angular applications and libraries.

Builders

Name Description
app-shell Build an Angular App shell.
browser Build an Angular application targeting a browser environment.
dev-server A development server that provides live reloading.
extract-i18n Extract i18n messages from an Angular application.
karma Execute unit tests using Karma test runner.
ng-packagr Build and package an Angular library in Angular Package Format (APF) format using ng-packagr.
server Build an Angular application targeting a Node.js environment.
protractor Deprecated - Run end-to-end tests using Protractor framework.

Disclaimer

While the builders when executed via the Angular CLI and their associated options are considered stable, the programmatic APIs are not considered officially supported and are not subject to the breaking change guarantees of SemVer.