mirror of
https://github.com/angular/angular.git
synced 2026-09-14 13:54:52 +08:00
950cf1894c
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
38 lines
762 B
Python
38 lines
762 B
Python
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",
|
|
],
|
|
)
|