Skip to content

v1.11.0

Compare
Choose a tag to compare
@github-actions github-actions released this 09 Dec 01:27
· 808 commits to main since this release
993d6fc

Using Bzlmod with Bazel 6:

Add to your MODULE.bazel file:

bazel_dep(name = "aspect_rules_js", version = "1.11.0")

npm = use_extension("@aspect_rules_js//npm:extensions.bzl", "npm", dev_dependency = True)

npm.npm_translate_lock(
    name = "npm",
    pnpm_lock = "//:pnpm-lock.yaml",
)

use_repo(npm, "npm")

Using WORKSPACE

Paste this snippet into your WORKSPACE file:

load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")

http_archive(
    name = "aspect_rules_js",
    sha256 = "9f316133cf2809dedaffd4328222d0ce7696c3e79a79c94a8a29aaef9cdf6f03",
    strip_prefix = "rules_js-1.11.0",
    url = "https://github.com/aspect-build/rules_js/archive/refs/tags/v1.11.0.tar.gz",
)

load("@aspect_rules_js//js:repositories.bzl", "rules_js_dependencies")

rules_js_dependencies()

load("@rules_nodejs//nodejs:repositories.bzl", "DEFAULT_NODE_VERSION", "nodejs_register_toolchains")

nodejs_register_toolchains(
    name = "nodejs",
    node_version = DEFAULT_NODE_VERSION,
)

load("@aspect_rules_js//npm:npm_import.bzl", "npm_translate_lock")

npm_translate_lock(
    name = "npm",
    pnpm_lock = "//:pnpm-lock.yaml",
    verify_node_modules_ignored = "//:.bazelignore",
)

load("@npm//:repositories.bzl", "npm_repositories")

npm_repositories()

What's Changed

  • chore: add a serve_simple_bin variant to js_run_devserver example by @gregmagolan in #686
  • feat: use settings in ~/.npmrc when use_home_npmrc is set to True in npm_translate_lock by @gregmagolan in #696
  • chore: use NPM_RC_FILENAME const since it is available by @gregmagolan in #697
  • fix: don't use utils.exists on Windows as it is not yet implemented by @gregmagolan in #700
  • feat: add support for '_auth' basic authentication in .npmrc by @gregmagolan in #698

Full Changelog: v1.10.0...v1.11.0