angular-docs-cn/packages/zone.js/dist/BUILD.bazel

40 lines
1019 B
Python

load("//packages/zone.js:bundles.bzl", "ES2015_BUNDLES", "ES5_BUNDLES", "ES5_GLOBAL_BUNDLES")
load("//packages/zone.js/dist:tools.bzl", "generate_dist", "zone_rollup_bundle")
package(default_visibility = ["//visibility:public"])
# copy this file from //lib to //dist
genrule(
name = "zone_externs",
srcs = ["//packages/zone.js/lib:closure/zone_externs.js"],
outs = ["zone_externs.js"],
cmd = "cp $< $@",
)
genrule(
name = "zone_d_ts",
srcs = ["//packages/zone.js/lib:zone_d_ts"],
outs = ["zone.js.d.ts"],
cmd = "cp $< $@",
)
zone_rollup_bundle(
bundles = ES5_BUNDLES.items(),
config_file = "//packages/zone.js:rollup-es5.config.js",
)
zone_rollup_bundle(
bundles = ES5_GLOBAL_BUNDLES.items() + ES2015_BUNDLES.items(),
config_file = "//packages/zone.js:rollup-es5_global-es2015.config.js",
)
generate_dist(
bundles = ES5_BUNDLES.items() + ES5_GLOBAL_BUNDLES.items(),
module = "es5",
)
generate_dist(
bundles = ES2015_BUNDLES.items(),
module = "",
)