2019-05-31 11:56:07 -04:00
|
|
|
load("//packages/zone.js:bundles.bzl", "ES2015_BUNDLES", "ES5_BUNDLES", "ES5_GLOBAL_BUNDLES")
|
2019-12-21 20:27:41 -05:00
|
|
|
load("//packages/zone.js/dist:tools.bzl", "generate_dist", "zone_rollup_bundle")
|
2019-05-31 11:56:07 -04:00
|
|
|
|
2019-10-05 23:06:53 -04:00
|
|
|
package(default_visibility = ["//visibility:public"])
|
2019-05-31 11:56:07 -04:00
|
|
|
|
|
|
|
# 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(
|
2020-02-10 14:23:58 -05:00
|
|
|
name = "zone_js_d_ts",
|
2019-10-05 23:06:53 -04:00
|
|
|
srcs = ["//packages/zone.js/lib:zone_d_ts"],
|
2019-05-31 11:56:07 -04:00
|
|
|
outs = ["zone.js.d.ts"],
|
2019-10-05 23:06:53 -04:00
|
|
|
cmd = "cp $< $@",
|
2019-05-31 11:56:07 -04:00
|
|
|
)
|
|
|
|
|
2020-02-10 14:23:58 -05:00
|
|
|
genrule(
|
|
|
|
name = "zone_extensions_d_ts",
|
|
|
|
srcs = ["//packages/zone.js/lib:zone.api.extensions.ts"],
|
|
|
|
outs = ["zone.api.extensions.ts"],
|
|
|
|
cmd = "cp $< $@",
|
|
|
|
)
|
|
|
|
|
|
|
|
filegroup(
|
|
|
|
name = "zone_d_ts",
|
|
|
|
srcs = [
|
|
|
|
":zone_extensions_d_ts",
|
|
|
|
":zone_js_d_ts",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
2019-12-21 20:27:41 -05:00
|
|
|
zone_rollup_bundle(
|
|
|
|
bundles = ES5_BUNDLES.items(),
|
|
|
|
config_file = "//packages/zone.js:rollup-es5.config.js",
|
|
|
|
)
|
2019-05-31 11:56:07 -04:00
|
|
|
|
2019-12-21 20:27:41 -05:00
|
|
|
zone_rollup_bundle(
|
|
|
|
bundles = ES5_GLOBAL_BUNDLES.items() + ES2015_BUNDLES.items(),
|
|
|
|
config_file = "//packages/zone.js:rollup-es5_global-es2015.config.js",
|
|
|
|
)
|
2019-05-31 11:56:07 -04:00
|
|
|
|
2019-12-21 20:27:41 -05:00
|
|
|
generate_dist(
|
|
|
|
bundles = ES5_BUNDLES.items() + ES5_GLOBAL_BUNDLES.items(),
|
|
|
|
module = "es5",
|
|
|
|
)
|
2019-05-31 11:56:07 -04:00
|
|
|
|
2019-12-21 20:27:41 -05:00
|
|
|
generate_dist(
|
|
|
|
bundles = ES2015_BUNDLES.items(),
|
|
|
|
module = "",
|
|
|
|
)
|