When pulling @bazel/typescript from npm, there is a bootstrap issue since a user's WORKSPACE will need to reference @build_bazel_rules_typescript,
load("@build_bazel_rules_typescript//:defs.bzl", "ts_setup_workspace")
ts_setup_workspace()
but until you run yarn or npm that file does not exist as it comes from node_modules,
local_repository(
name = "build_bazel_rules_typescript",
path = "node_modules/@bazel/typescript",
)
This means that you can't run bazel run @nodejs//:yarn without first running a locally installed version of yarn or npm.
When pulling @bazel/typescript from npm, there is a bootstrap issue since a user's WORKSPACE will need to reference @build_bazel_rules_typescript,
but until you run
yarnornpmthat file does not exist as it comes fromnode_modules,This means that you can't run
bazel run @nodejs//:yarnwithout first running a locally installed version ofyarnornpm.