angular/adev/shared-docs/pipeline/tutorials/BUILD.bazel
Joey Perrott e8c5603126 build: move all rule/macro loading into adev/defaults.bzl and fix intellisense loading (#62627)
Move all of our loading into a local defaults.bzl file instead of mixed loading via tools/defaults and adev/defaults

PR Close #62627
2025-07-14 15:47:05 -07:00

84 lines
1.9 KiB
Text

load("//adev/shared-docs:defaults.bzl", "esbuild", "ts_project")
package(default_visibility = ["//visibility:public"])
ts_project(
name = "editor",
srcs = glob(
[
"*.mts",
],
exclude = [
"playground_index.mts",
"tutorial_index.mts",
],
),
enable_runtime_rnjs_interop = True,
deps = [
"//adev:node_modules/@types/node",
"//adev:node_modules/@webcontainer/api",
"//adev:node_modules/tinyglobby",
"//adev/shared-docs/interfaces:interfaces_rjs",
],
)
ts_project(
name = "playground",
srcs = [
"playground_index.mts",
],
enable_runtime_rnjs_interop = True,
visibility = [
"//adev/shared-docs:__subpackages__",
],
deps = [
":editor_rjs",
"//adev:node_modules/@types/node",
"//adev/shared-docs/interfaces:interfaces_rjs",
],
)
ts_project(
name = "tutorial",
srcs = [
"tutorial_index.mts",
],
visibility = [
"//adev/shared-docs:__subpackages__",
],
deps = [
":editor_rjs",
"//adev:node_modules/@types/node",
"//adev/shared-docs/interfaces:interfaces_rjs",
],
)
esbuild(
name = "playground_bundle",
config = "//adev/shared-docs/pipeline:esbuild-config",
entry_point = ":playground_index.mts",
format = "esm",
output = "playground.mjs",
platform = "node",
target = "es2022",
tsconfig = "//adev/shared-docs:tsconfig_build",
visibility = ["//visibility:public"],
deps = [
":playground_rjs",
],
)
esbuild(
name = "tutorial_bundle",
config = "//adev/shared-docs/pipeline:esbuild-config",
entry_point = ":tutorial_index.mts",
format = "esm",
output = "tutorial.mjs",
platform = "node",
target = "es2022",
tsconfig = "//adev/shared-docs:tsconfig_build",
visibility = ["//visibility:public"],
deps = [
":tutorial_rjs",
],
)