Currently all playground examples are built with NGC, and most of the HTML resources are automatically inlined. Surprisingly NGC is able to resolve the relative component assets even though these aren't specified in the `assets`. This seems to work because NGC resolves the files in the execroot where the files are present (if Bazel doesn't use sandboxing). Issue is tracked with TOOL-667 PR Close #28562
37 lines
1.1 KiB
Python
37 lines
1.1 KiB
Python
load("//tools:defaults.bzl", "ng_module")
|
|
load("@build_bazel_rules_typescript//:defs.bzl", "ts_devserver")
|
|
|
|
package(default_visibility = ["//modules/playground:__subpackages__"])
|
|
|
|
ng_module(
|
|
name = "todo",
|
|
srcs = glob(["**/*.ts"]),
|
|
assets = ["todo.html"],
|
|
tsconfig = "//modules/playground:tsconfig-build.json",
|
|
# TODO: FW-1004 Type checking is currently not complete.
|
|
type_check = False,
|
|
deps = [
|
|
"//packages/core",
|
|
"//packages/forms",
|
|
"//packages/platform-webworker",
|
|
"//packages/platform-webworker-dynamic",
|
|
],
|
|
)
|
|
|
|
ts_devserver(
|
|
name = "devserver",
|
|
data = [
|
|
"css/main.css",
|
|
"loader.js",
|
|
"//modules/playground/src/web_workers:worker-config",
|
|
"@ngdeps//node_modules/rxjs:bundles/rxjs.umd.js",
|
|
"@ngdeps//node_modules/tslib:tslib.js",
|
|
],
|
|
entry_module = "angular/modules/playground/src/web_workers/todo/index",
|
|
index_html = "index.html",
|
|
port = 4200,
|
|
scripts = ["@ngdeps//node_modules/tslib:tslib.js"],
|
|
static_files = ["@ngdeps//node_modules/zone.js:dist/zone.js"],
|
|
deps = [":todo"],
|
|
)
|