mirror of
https://github.com/angular/angular
synced 2026-05-24 09:28:37 +00:00
Switches the benchpress NPM package to APF with ESM. This is necessary as benchpress relies on framework APF strict ESM packages. CommonJS packages like benchpress currently are not able to import from strict ESM packages without adding a CJS/ESM interop that complicates code unnecessarily. The best way forward is to just switch the benchpress package from CommonJS to the modern ESM output, matching with the Angular ecosystem. PR Close #44893
37 lines
762 B
Text
37 lines
762 B
Text
load("//tools:defaults.bzl", "ng_package", "ts_library")
|
|
|
|
package(default_visibility = ["//visibility:public"])
|
|
|
|
ts_library(
|
|
name = "benchpress",
|
|
srcs = glob(
|
|
[
|
|
"*.ts",
|
|
"src/**/*.ts",
|
|
],
|
|
),
|
|
deps = [
|
|
"//packages:types",
|
|
"//packages/core",
|
|
"@npm//@types/node",
|
|
"@npm//reflect-metadata",
|
|
],
|
|
)
|
|
|
|
ng_package(
|
|
name = "npm_package",
|
|
srcs = [
|
|
"README.md",
|
|
"package.json",
|
|
],
|
|
externals = [
|
|
"@angular/core",
|
|
"reflect-metadata",
|
|
],
|
|
# Do not add more to this list.
|
|
# Dependencies on the full npm_package cause long re-builds.
|
|
visibility = ["//integration:__subpackages__"],
|
|
deps = [
|
|
":benchpress",
|
|
],
|
|
)
|