angular/modules/benchmarks/src
Paul Gschwendtner c8cd5d5f2c build: switch all instances from ng_rollup_bundle to app_bundle (#44490)
The `ng_rollup_bundle` rule has been replaced with a new rule called
`app_bundle`. This rule replicates the Angular v13 optimization
pipeline in the CLI, so that we can get better benchmarking results.
Also the rule is much simpler to maintain as it relies on ESbuild.

The old `ng_rollup_bundle` rule did rely on e.g. build-optimizer that no
longer has an effect on v13 Angular packages, so technically size
tests/symbol tests were no longer as correct as they were before. This
commit fixes that.

A couple of different changes and their explanation:

* Language-service will no longer use the benchmark rule for creating
  its NPM bundles! It will use plain `rollup_bundle`. ESBuild would have
  been nice but the language-service relies on AMD that ESBuild cannot
  generate (yet?)

* Service-worker ngsw-worker.js file was generated using the benchmark
  bundle rule. This is wrong. We will use a simple ESbuild rule in the
  future. The output is more predictable that way, and we can have a
  clear use of the benchmark bundle rule..

* A couple of benchmarks in `modules/` had to be updated to use e.g.
  `initTableUtils` calls. This is done because with the new rule, all
  files except for the entry-point are considered side-effect free. The
  utilities for benchmarks relied on side-effects in some
  transitively-loaded file (bad practice anyway IMO). We are now
  initializing the utilities using a proper init function that is
  exported...

PR Close #44490
2022-01-04 12:14:14 -08:00
..
change_detection build: switch all instances from ng_rollup_bundle to app_bundle (#44490) 2022-01-04 12:14:14 -08:00
class_bindings build: remove dev-infra directory and migrate to relying on @angular/dev-infra-private-builds (#43061) 2021-08-16 10:44:27 -07:00
expanding_rows build: switch all instances from ng_rollup_bundle to app_bundle (#44490) 2022-01-04 12:14:14 -08:00
js-web-frameworks build: switch all instances from ng_rollup_bundle to app_bundle (#44490) 2022-01-04 12:14:14 -08:00
largeform build: remove dev-infra directory and migrate to relying on @angular/dev-infra-private-builds (#43061) 2021-08-16 10:44:27 -07:00
largetable build: switch all instances from ng_rollup_bundle to app_bundle (#44490) 2022-01-04 12:14:14 -08:00
old build: bundle spec files for saucelabs legacy job (#44281) 2021-11-30 11:56:04 -05:00
styling build: switch all instances from ng_rollup_bundle to app_bundle (#44490) 2022-01-04 12:14:14 -08:00
tree build: switch all instances from ng_rollup_bundle to app_bundle (#44490) 2022-01-04 12:14:14 -08:00
views build: switch all instances from ng_rollup_bundle to app_bundle (#44490) 2022-01-04 12:14:14 -08:00
bootstrap_ng2.ts build: update license headers to reference Google LLC (#37205) 2020-05-26 14:26:58 -04:00
bootstrap_plain.ts build: update license headers to reference Google LLC (#37205) 2020-05-26 14:26:58 -04:00
BUILD.bazel style: enforce buildifier lint on CI (#28186) 2019-02-26 16:57:41 -08:00
README.md build(bazel): //modules/benchmarks/src/largetable/render3:perf bazel protractor test (#24788) 2018-07-24 08:26:16 -07:00
util.ts build: update license headers to reference Google LLC (#37205) 2020-05-26 14:26:58 -04:00

Benchmark Directory Layout

Bazel

Under bazel the rules for laying out test files are slightly different. Use largetable/render3 as an example.

Put the perf file in current subdirectory (ie largetable) such that the same perf file can be used for each of the sub-subdirectories. (ie largetable/* should all be testable with the same perf file largetable/largetable_perf.spec.ts). Under bazel, typescript protractor spec files must end with .spec.ts or .test.ts.