diff --git a/.aspect/rules/external_repository_action_cache/npm_translate_lock_LTkzNjczMzk3Mw== b/.aspect/rules/external_repository_action_cache/npm_translate_lock_LTkzNjczMzk3Mw== index 9c71d7b37..55b61f5fa 100755 --- a/.aspect/rules/external_repository_action_cache/npm_translate_lock_LTkzNjczMzk3Mw== +++ b/.aspect/rules/external_repository_action_cache/npm_translate_lock_LTkzNjczMzk3Mw== @@ -20,7 +20,7 @@ github-actions/pull-request-labeling/package.json=-197755049 github-actions/saucelabs/package.json=855472374 github-actions/unified-status-check/package.json=-337882335 ng-dev/package.json=1323489217 -package.json=-1202209611 -pnpm-lock.yaml=-1602715196 +package.json=-791801366 +pnpm-lock.yaml=-1788436055 pnpm-workspace.yaml=1110472849 yarn.lock=-598328143 diff --git a/.github/local-actions/branch-manager/BUILD.bazel b/.github/local-actions/branch-manager/BUILD.bazel index 2edbb153e..ce0e1e784 100644 --- a/.github/local-actions/branch-manager/BUILD.bazel +++ b/.github/local-actions/branch-manager/BUILD.bazel @@ -16,19 +16,19 @@ ts_project( "//.github/local-actions/branch-manager:node_modules/@types/node", "//.github/local-actions/branch-manager:node_modules/typed-graphqlify", "//.github/local-actions/branch-manager:node_modules/undici", - "//github-actions:utils_rjs", - "//ng-dev/pr/common:common_rjs", - "//ng-dev/pr/common/labels:labels_rjs", - "//ng-dev/pr/config:config_rjs", - "//ng-dev/pr/merge:merge_rjs", - "//ng-dev/utils:utils_rjs", + "//github-actions:utils", + "//ng-dev/pr/common", + "//ng-dev/pr/common/labels", + "//ng-dev/pr/config", + "//ng-dev/pr/merge", + "//ng-dev/utils", ], ) esbuild_checked_in( name = "main", srcs = [ - ":lib_rjs", + ":lib", ], entry_point = "lib/main.ts", format = "esm", diff --git a/.github/local-actions/labels-sync/BUILD.bazel b/.github/local-actions/labels-sync/BUILD.bazel index 7de4be497..e3d19d0ee 100644 --- a/.github/local-actions/labels-sync/BUILD.bazel +++ b/.github/local-actions/labels-sync/BUILD.bazel @@ -16,15 +16,15 @@ ts_project( "//.github/local-actions/labels-sync:node_modules/@octokit/types", "//.github/local-actions/labels-sync:node_modules/@types/node", "//.github/local-actions/labels-sync:node_modules/undici", - "//github-actions:utils_rjs", - "//ng-dev/pr/common/labels:labels_rjs", + "//github-actions:utils", + "//ng-dev/pr/common/labels", ], ) esbuild_checked_in( name = "main", srcs = [ - ":lib_rjs", + ":lib", ], entry_point = "lib/main.ts", format = "esm", diff --git a/.github/local-actions/lock-closed/BUILD.bazel b/.github/local-actions/lock-closed/BUILD.bazel index 21b40c40d..c2f49849d 100644 --- a/.github/local-actions/lock-closed/BUILD.bazel +++ b/.github/local-actions/lock-closed/BUILD.bazel @@ -15,14 +15,14 @@ ts_project( "//.github/local-actions/lock-closed:node_modules/@octokit/rest", "//.github/local-actions/lock-closed:node_modules/@types/node", "//.github/local-actions/lock-closed:node_modules/undici", - "//github-actions:utils_rjs", + "//github-actions:utils", ], ) esbuild_checked_in( name = "main", srcs = [ - ":lib_rjs", + ":lib", ], entry_point = "lib/main.ts", format = "esm", diff --git a/BUILD.bazel b/BUILD.bazel index 45f41f38e..ef8ea8af3 100644 --- a/BUILD.bazel +++ b/BUILD.bazel @@ -1,15 +1,10 @@ -load("@aspect_rules_ts//ts:defs.bzl", rules_js_tsconfig = "ts_config") -load("@build_bazel_rules_nodejs//:index.bzl", "nodejs_binary", "pkg_npm") load("@devinfra_npm//:defs.bzl", "npm_link_all_packages") -load("@npm//@bazel/typescript:index.bzl", "ts_config") - -# BEGIN-INTERNAL -load("//:package.bzl", "NPM_PACKAGE_SUBSTITUTIONS") +load("//tools:defaults2.bzl", "js_binary", "ts_config") npm_link_all_packages() -rules_js_tsconfig( - name = "rjs-tsconfig", +ts_config( + name = "tsconfig", src = "tsconfig.json", visibility = ["//visibility:public"], ) @@ -19,52 +14,16 @@ exports_files([ ".yarnrc.yml", ]) -ts_config( - name = "tsconfig", - src = "tsconfig.json", - visibility = ["//visibility:public"], -) - -nodejs_binary( +js_binary( name = "yarn_berry_vendored", data = [".yarn/releases/yarn-4.9.1.cjs"], entry_point = ".yarn/releases/yarn-4.9.1.cjs", visibility = ["//bazel/integration/tests:__subpackages__"], ) -nodejs_binary( +js_binary( name = "yarn_classic_vendored", data = [".yarn/releases/yarn-1.22.17.cjs"], entry_point = ".yarn/releases/yarn-1.22.17.cjs", visibility = ["//bazel/integration/tests:__subpackages__"], ) - -package_group( - name = "npm", - packages = [ - "//", - ], -) - -pkg_npm( - name = "npm_package", - package_name = "@angular/build-tooling", - srcs = [ - "BUILD.bazel", - "package.json", - "tsconfig.json", - ":index.bzl", - "//bazel:static_files", - "//lint-rules/stylelint:static_files", - "//lint-rules/tslint:static_files", - "//shared-scripts:static_files", - ], - substitutions = NPM_PACKAGE_SUBSTITUTIONS, - deps = [ - "//lint-rules/stylelint:lib", - "//lint-rules/tslint:lib", - ], -) -# END-INTERNAL - -exports_files(["tsconfig.json"]) diff --git a/WORKSPACE b/WORKSPACE index 997dad618..81a059b59 100644 --- a/WORKSPACE +++ b/WORKSPACE @@ -209,3 +209,13 @@ rules_angular_step3( angular_compiler_cli = "@devinfra//:node_modules/@angular/compiler-cli", typescript = "@devinfra//:node_modules/typescript", ) + +git_repository( + name = "rules_sass", + commit = "cc1e845339fc45d3c8390445014d5824b85a0948", + remote = "https://github.com/devversion/rules_sass.git", +) + +load("@rules_sass//src/toolchain:repositories.bzl", "setup_rules_sass") + +setup_rules_sass() diff --git a/apps/BUILD.bazel b/apps/BUILD.bazel index 67980b550..6c8ae99ae 100644 --- a/apps/BUILD.bazel +++ b/apps/BUILD.bazel @@ -1,4 +1,13 @@ -load("@build_bazel_rules_nodejs//:index.bzl", "copy_to_bin", "nodejs_binary") +load("@devinfra_npm//:firebase-tools/package_json.bzl", firebase = "bin") +load("//tools:defaults2.bzl", "copy_to_bin", "ts_config") + +ts_config( + name = "tsconfig", + src = "tsconfig.json", + visibility = [ + "//apps:__subpackages__", + ], +) copy_to_bin( name = "static_runfiles", @@ -10,7 +19,7 @@ copy_to_bin( ], ) -nodejs_binary( +firebase.firebase_binary( name = "serve", chdir = package_name(), data = [ @@ -18,24 +27,22 @@ nodejs_binary( ":static_runfiles", # Firebase function files - "//apps/functions:functions_compiled", "//apps/functions:functions_files", # Firebase hosted application files "//apps/code-of-conduct:application_files", ], - entry_point = "@npm//:node_modules/firebase-tools/lib/bin/firebase.js", - tags = ["ibazel_notify_changes"], - templated_args = [ + fixed_args = [ "--project", "internal-200822", "--config", "firebase.json", "emulators:start", ], + tags = ["ibazel_notify_changes"], ) -nodejs_binary( +firebase.firebase_binary( name = "deploy", chdir = package_name(), data = [ @@ -43,14 +50,13 @@ nodejs_binary( ":static_runfiles", # Firebase function files - "//apps/functions:functions_compiled", "//apps/functions:functions_files", # Firebase hosted application files "//apps/code-of-conduct:application_files", + "//:node_modules/firebase-functions", ], - entry_point = "@npm//:node_modules/firebase-tools/lib/bin/firebase.js", - templated_args = [ + fixed_args = [ "--project", "internal-200822", "--config", diff --git a/apps/code-of-conduct/BUILD.bazel b/apps/code-of-conduct/BUILD.bazel index 5da595cb8..964ba8498 100644 --- a/apps/code-of-conduct/BUILD.bazel +++ b/apps/code-of-conduct/BUILD.bazel @@ -1,79 +1,59 @@ -load("//tools:defaults.bzl", "esbuild", "esbuild_config", "ng_module") -load("@io_bazel_rules_sass//:defs.bzl", "npm_sass_library", "sass_binary") -load("@build_bazel_rules_nodejs//:index.bzl", "copy_to_bin") +load("//tools:defaults2.bzl", "copy_to_bin", "esbuild", "ng_project", "npm_sass_library", "sass_binary") package(default_visibility = ["//apps/code-of-conduct:__subpackages__"]) -ng_module( +ng_project( name = "main", srcs = [ "environment.ts", "main.ts", ], deps = [ + "//:node_modules/@angular/common", + "//:node_modules/@angular/compiler", + "//:node_modules/@angular/fire", + "//:node_modules/@angular/platform-browser", + "//:node_modules/@angular/router", + "//:node_modules/zone.js", "//apps/code-of-conduct/app", "//apps/code-of-conduct/app:app_routes", - "@npm//@angular/common", - "@npm//@angular/compiler", - "@npm//@angular/fire", - "@npm//@angular/platform-browser", - "@npm//@angular/router", - "@npm//zone.js", ], ) npm_sass_library( name = "angular_material_sass_deps", - deps = ["@npm//@angular/material"], + deps = [ + "//:node_modules/@angular/cdk", + "//:node_modules/@angular/material", + ], ) sass_binary( name = "styles", src = "styles.scss", - include_paths = [ - "external/npm/node_modules", - ], deps = [ ":angular_material_sass_deps", ], ) -esbuild_config( - name = "esbuild_config", - config_file = "esbuild.config.mjs", - deps = [ - "//shared-scripts/angular-optimization:js_lib", - "@npm//@angular/compiler-cli", - ], -) - esbuild( - name = "bundles", - config = ":esbuild_config", - entry_points = [":main.ts"], - platform = "browser", - target = "es2016", - deps = [ + name = "bundle", + srcs = [ ":main", ], + entry_points = [":main.js"], + platform = "browser", + target = "es2022", ) copy_to_bin( - name = "application_files_in_bin", + name = "application_files", srcs = [ "favicon.ico", "index.html", "robots.txt", - ], -) - -filegroup( - name = "application_files", - srcs = [ - ":application_files_in_bin", - ":bundles", + ":bundle", ":styles", - "@npm//:node_modules/zone.js/bundles/zone.umd.min.js", ], visibility = ["//apps:__pkg__"], ) diff --git a/apps/code-of-conduct/app/BUILD.bazel b/apps/code-of-conduct/app/BUILD.bazel index 78a4b4658..2bc520014 100644 --- a/apps/code-of-conduct/app/BUILD.bazel +++ b/apps/code-of-conduct/app/BUILD.bazel @@ -1,9 +1,8 @@ -load("@io_bazel_rules_sass//:defs.bzl", "sass_binary") -load("//tools:defaults.bzl", "ng_module") +load("//tools:defaults2.bzl", "ng_project", "sass_binary") package(default_visibility = ["//apps/code-of-conduct:__subpackages__"]) -ng_module( +ng_project( name = "app", srcs = [ "app.component.ts", @@ -13,12 +12,12 @@ ng_module( "app.component.html", ], deps = [ + "//:node_modules/@angular/common", + "//:node_modules/@angular/core", + "//:node_modules/@angular/router", "//apps/code-of-conduct/app/account", "//apps/code-of-conduct/app/block-user", "//apps/code-of-conduct/app/user-table", - "@npm//@angular/common", - "@npm//@angular/core", - "@npm//@angular/router", ], ) @@ -27,29 +26,29 @@ sass_binary( src = "app.component.scss", ) -ng_module( +ng_project( name = "block_service", srcs = [ "block.service.ts", ], deps = [ - "@npm//@angular/common", - "@npm//@angular/core", - "@npm//@angular/fire", - "@npm//@angular/material", - "@npm//rxjs", + "//:node_modules/@angular/common", + "//:node_modules/@angular/core", + "//:node_modules/@angular/fire", + "//:node_modules/@angular/material", + "//:node_modules/rxjs", ], ) -ng_module( +ng_project( name = "app_routes", srcs = [ "app.routes.ts", ], deps = [ + "//:node_modules/@angular/router", "//apps/code-of-conduct/app/account", "//apps/code-of-conduct/app/login", "//apps/code-of-conduct/app/main", - "@npm//@angular/router", ], ) diff --git a/apps/code-of-conduct/app/account/BUILD.bazel b/apps/code-of-conduct/app/account/BUILD.bazel index a954bdbf6..e7aad5963 100644 --- a/apps/code-of-conduct/app/account/BUILD.bazel +++ b/apps/code-of-conduct/app/account/BUILD.bazel @@ -1,7 +1,6 @@ -load("@io_bazel_rules_sass//:defs.bzl", "sass_binary") -load("//tools:defaults.bzl", "ng_module") +load("//tools:defaults2.bzl", "ng_project", "sass_binary") -ng_module( +ng_project( name = "account", srcs = glob(["*.ts"]), assets = [ @@ -12,14 +11,14 @@ ng_module( "//apps:__subpackages__", ], deps = [ - "@npm//@angular/cdk", - "@npm//@angular/common", - "@npm//@angular/core", - "@npm//@angular/fire", - "@npm//@angular/material", - "@npm//@angular/router", - "@npm//@octokit/rest", - "@npm//rxjs", + "//:node_modules/@angular/cdk", + "//:node_modules/@angular/common", + "//:node_modules/@angular/core", + "//:node_modules/@angular/fire", + "//:node_modules/@angular/material", + "//:node_modules/@angular/router", + "//:node_modules/@octokit/rest", + "//:node_modules/rxjs", ], ) diff --git a/apps/code-of-conduct/app/block-user/BUILD.bazel b/apps/code-of-conduct/app/block-user/BUILD.bazel index 7f7eb08c5..5cc7e4082 100644 --- a/apps/code-of-conduct/app/block-user/BUILD.bazel +++ b/apps/code-of-conduct/app/block-user/BUILD.bazel @@ -1,9 +1,8 @@ -load("//tools:defaults.bzl", "ng_module") -load("@io_bazel_rules_sass//:defs.bzl", "sass_binary") +load("//tools:defaults2.bzl", "ng_project", "sass_binary") package(default_visibility = ["//apps/code-of-conduct:__subpackages__"]) -ng_module( +ng_project( name = "block-user", srcs = glob( ["*.ts"], @@ -14,12 +13,12 @@ ng_module( ":block-user.component.html", ], deps = [ + "//:node_modules/@angular/common", + "//:node_modules/@angular/core", + "//:node_modules/@angular/fire", + "//:node_modules/@angular/forms", + "//:node_modules/@angular/material", "//apps/code-of-conduct/app:block_service", - "@npm//@angular/common", - "@npm//@angular/core", - "@npm//@angular/fire", - "@npm//@angular/forms", - "@npm//@angular/material", ], ) diff --git a/apps/code-of-conduct/app/login/BUILD.bazel b/apps/code-of-conduct/app/login/BUILD.bazel index d90980b3c..523a73027 100644 --- a/apps/code-of-conduct/app/login/BUILD.bazel +++ b/apps/code-of-conduct/app/login/BUILD.bazel @@ -1,9 +1,8 @@ -load("@io_bazel_rules_sass//:defs.bzl", "sass_binary") -load("//tools:defaults.bzl", "ng_module") +load("//tools:defaults2.bzl", "ng_project", "sass_binary") package(default_visibility = ["//apps/code-of-conduct:__subpackages__"]) -ng_module( +ng_project( name = "login", srcs = glob(["*.ts"]), assets = [ @@ -11,10 +10,10 @@ ng_module( "login.component.html", ], deps = [ + "//:node_modules/@angular/common", + "//:node_modules/@angular/core", + "//:node_modules/@angular/material", "//apps/code-of-conduct/app/account", - "@npm//@angular/common", - "@npm//@angular/core", - "@npm//@angular/material", ], ) diff --git a/apps/code-of-conduct/app/main/BUILD.bazel b/apps/code-of-conduct/app/main/BUILD.bazel index 4c5972c0a..eb7ed489b 100644 --- a/apps/code-of-conduct/app/main/BUILD.bazel +++ b/apps/code-of-conduct/app/main/BUILD.bazel @@ -1,9 +1,8 @@ -load("//tools:defaults.bzl", "ng_module") -load("@io_bazel_rules_sass//:defs.bzl", "sass_binary") +load("//tools:defaults2.bzl", "ng_project", "sass_binary") package(default_visibility = ["//apps/code-of-conduct:__subpackages__"]) -ng_module( +ng_project( name = "main", srcs = glob(["*.ts"]), assets = [ @@ -11,11 +10,11 @@ ng_module( "main.component.html", ], deps = [ + "//:node_modules/@angular/common", + "//:node_modules/@angular/core", + "//:node_modules/@angular/material", "//apps/code-of-conduct/app/block-user", "//apps/code-of-conduct/app/user-table", - "@npm//@angular/common", - "@npm//@angular/core", - "@npm//@angular/material", ], ) diff --git a/apps/code-of-conduct/app/user-table/BUILD.bazel b/apps/code-of-conduct/app/user-table/BUILD.bazel index 21a11b5d7..0bbeae30b 100644 --- a/apps/code-of-conduct/app/user-table/BUILD.bazel +++ b/apps/code-of-conduct/app/user-table/BUILD.bazel @@ -1,9 +1,8 @@ -load("//tools:defaults.bzl", "ng_module") -load("@io_bazel_rules_sass//:defs.bzl", "sass_binary") +load("//tools:defaults2.bzl", "ng_project", "sass_binary") package(default_visibility = ["//apps/code-of-conduct:__subpackages__"]) -ng_module( +ng_project( name = "user-table", srcs = glob(["*.ts"]), assets = [ @@ -11,11 +10,11 @@ ng_module( "user-table.component.html", ], deps = [ + "//:node_modules/@angular/common", + "//:node_modules/@angular/core", + "//:node_modules/@angular/material", "//apps/code-of-conduct/app:block_service", "//apps/code-of-conduct/app/block-user", - "@npm//@angular/common", - "@npm//@angular/core", - "@npm//@angular/material", ], ) diff --git a/apps/code-of-conduct/esbuild.config.mjs b/apps/code-of-conduct/esbuild.config.mjs deleted file mode 100644 index a2f888866..000000000 --- a/apps/code-of-conduct/esbuild.config.mjs +++ /dev/null @@ -1,24 +0,0 @@ -/** - * @license - * Copyright Google LLC All Rights Reserved. - * - * Use of this source code is governed by an MIT-style license that can be - * found in the LICENSE file at https://angular.io/license - */ -import {createEsbuildAngularOptimizePlugin} from '../../shared-scripts/angular-optimization/esbuild-plugin.mjs'; - -export default { - // Note: We support `.mjs` here as this is the extension used by Angular APF packages. - resolveExtensions: ['.mjs', '.js'], - format: 'esm', - plugins: [ - await createEsbuildAngularOptimizePlugin({ - enableLinker: { - linkerOptions: { - // We enable JIT mode as unit tests may need it for overriding. - linkerJitMode: true, - }, - }, - }), - ], -}; diff --git a/apps/code-of-conduct/index.html b/apps/code-of-conduct/index.html index c773ab7e6..5d46bd580 100644 --- a/apps/code-of-conduct/index.html +++ b/apps/code-of-conduct/index.html @@ -14,5 +14,5 @@ - + diff --git a/apps/code-of-conduct/main.ts b/apps/code-of-conduct/main.ts index fd16e553b..a2b0d5d1f 100644 --- a/apps/code-of-conduct/main.ts +++ b/apps/code-of-conduct/main.ts @@ -1,4 +1,5 @@ import 'zone.js'; +import '@angular/compiler'; import {enableProdMode, importProvidersFrom} from '@angular/core'; import {initializeApp, provideFirebaseApp} from '@angular/fire/app'; import {getAuth, provideAuth} from '@angular/fire/auth'; diff --git a/apps/functions/BUILD.bazel b/apps/functions/BUILD.bazel index b2fb2eb5d..d8035f9e6 100644 --- a/apps/functions/BUILD.bazel +++ b/apps/functions/BUILD.bazel @@ -1,5 +1,4 @@ -load("@build_bazel_rules_nodejs//:index.bzl", "copy_to_bin") -load("//tools:defaults.bzl", "esbuild_cjs_bundle", "ts_library") +load("//tools:defaults2.bzl", "copy_to_bin", "esbuild", "ts_project") package(default_visibility = ["//visibility:private"]) @@ -7,30 +6,32 @@ copy_to_bin( name = "functions_files", srcs = [ "package.json", + ":bundle", + "//:node_modules/firebase-tools", ], visibility = ["//apps:__pkg__"], ) -ts_library( +ts_project( name = "functions", srcs = [ "index.ts", ], deps = [ + "//:node_modules/firebase-admin", "//apps/functions/code-of-conduct", "//apps/functions/dns-redirecting", - "@npm//firebase-admin", ], ) -esbuild_cjs_bundle( - name = "functions_compiled", - entry_points = [ - "index.ts", - ], - visibility = ["//apps:__pkg__"], - deps = [ +esbuild( + name = "bundle", + srcs = [ ":functions", - "@npm//firebase-functions", + "//:node_modules/firebase-functions", ], + entry_point = "index.ts", + format = "cjs", + platform = "node", + visibility = ["//apps:__pkg__"], ) diff --git a/apps/functions/code-of-conduct/BUILD.bazel b/apps/functions/code-of-conduct/BUILD.bazel index 42bda03b1..e8111e995 100644 --- a/apps/functions/code-of-conduct/BUILD.bazel +++ b/apps/functions/code-of-conduct/BUILD.bazel @@ -1,8 +1,8 @@ -load("//tools:defaults.bzl", "ts_library") +load("//tools:defaults2.bzl", "ts_project") package(default_visibility = ["//visibility:private"]) -ts_library( +ts_project( name = "code-of-conduct", srcs = [ "index.ts", @@ -12,11 +12,11 @@ ts_library( ], deps = [ ":lib", - "@npm//firebase-admin", + "//:node_modules/firebase-admin", ], ) -ts_library( +ts_project( name = "lib", srcs = [ "blockUser.ts", @@ -25,12 +25,12 @@ ts_library( "unblockUser.ts", ], deps = [ - "@npm//@octokit/auth-app", - "@npm//@octokit/request-error", - "@npm//@octokit/rest", - "@npm//@octokit/webhooks-types", - "@npm//@types/node", - "@npm//firebase-admin", - "@npm//firebase-functions", + "//:node_modules/@octokit/auth-app", + "//:node_modules/@octokit/request-error", + "//:node_modules/@octokit/rest", + "//:node_modules/@octokit/webhooks-types", + "//:node_modules/@types/node", + "//:node_modules/firebase-admin", + "//:node_modules/firebase-functions", ], ) diff --git a/apps/functions/dns-redirecting/BUILD.bazel b/apps/functions/dns-redirecting/BUILD.bazel index 94dd7e250..6cd297665 100644 --- a/apps/functions/dns-redirecting/BUILD.bazel +++ b/apps/functions/dns-redirecting/BUILD.bazel @@ -1,8 +1,8 @@ -load("//tools:defaults.bzl", "ts_library") +load("//tools:defaults2.bzl", "ts_project") package(default_visibility = ["//visibility:private"]) -ts_library( +ts_project( name = "dns-redirecting", srcs = [ "index.ts", @@ -11,6 +11,6 @@ ts_library( "//apps/functions:__pkg__", ], deps = [ - "@npm//firebase-functions", + "//:node_modules/firebase-functions", ], ) diff --git a/apps/functions/package.json b/apps/functions/package.json index bed8166f0..cfeccdaa8 100644 --- a/apps/functions/package.json +++ b/apps/functions/package.json @@ -3,7 +3,7 @@ "engines": { "node": "20" }, - "main": "functions_compiled/index.cjs", + "main": "bundle.js", "type": "module", "private": true } diff --git a/apps/tsconfig.json b/apps/tsconfig.json index c1a1c7102..4226d0dce 100644 --- a/apps/tsconfig.json +++ b/apps/tsconfig.json @@ -1,4 +1,28 @@ -// IDE config. Compile options should be changed in the top-level project config. { - "extends": "../tsconfig.json" + "compilerOptions": { + "declaration": true, + "stripInternal": true, + "removeComments": true, + "noImplicitAny": true, + "noImplicitOverride": true, + "strictNullChecks": true, + "noImplicitReturns": true, + "noPropertyAccessFromIndexSignature": true, + "esModuleInterop": true, + "strict": true, + "noFallthroughCasesInSwitch": true, + "moduleResolution": "node", + "module": "esnext", + "target": "es2020", + "lib": ["es2021", "dom"], + "skipLibCheck": true, + "types": ["node", "jasmine"], + "experimentalDecorators": true, + // This is needed due to https://github.com/Microsoft/TypeScript/issues/17516. + // As tsickle will lower decorators before TS, this is not a problem for our build. + "emitDecoratorMetadata": true, + "sourceMap": true, + "inlineSources": true, + "importHelpers": true + } } diff --git a/bazel/BUILD.bazel b/bazel/BUILD.bazel index 54ce8fc57..8656d6588 100644 --- a/bazel/BUILD.bazel +++ b/bazel/BUILD.bazel @@ -11,22 +11,3 @@ ts_config( "//bazel:node_modules/@types/node", ], ) - -filegroup( - name = "static_files", - srcs = [ - "BUILD.bazel", - "expand_template.bzl", - "extract_types.bzl", - "filter_outputs.bzl", - "//bazel/api-golden:files", - "//bazel/constraints:files", - "//bazel/git-toolchain:files", - "//bazel/http-server:files", - "//bazel/private:files", - "//bazel/remote-execution:files", - "//bazel/spec-bundling:files", - "//bazel/ts_project:files", - ], - visibility = ["//:npm"], -) diff --git a/bazel/api-golden/BUILD.bazel b/bazel/api-golden/BUILD.bazel index 549f7a4c7..32e1529b7 100644 --- a/bazel/api-golden/BUILD.bazel +++ b/bazel/api-golden/BUILD.bazel @@ -24,9 +24,3 @@ ts_project( "//bazel:node_modules/typescript", ], ) - -# Expose the sources in the dev-infra NPM package. -filegroup( - name = "files", - srcs = glob(["*"]), -) diff --git a/bazel/constraints/BUILD.bazel b/bazel/constraints/BUILD.bazel index 633a4833d..9a7045c83 100644 --- a/bazel/constraints/BUILD.bazel +++ b/bazel/constraints/BUILD.bazel @@ -31,9 +31,3 @@ config_setting( "@platforms//cpu:x86_64", ], ) - -# Make source files available for distribution via pkg_npm -filegroup( - name = "files", - srcs = glob(["*"]), -) diff --git a/bazel/git-toolchain/BUILD.bazel b/bazel/git-toolchain/BUILD.bazel index 16764d2cc..d3a577901 100644 --- a/bazel/git-toolchain/BUILD.bazel +++ b/bazel/git-toolchain/BUILD.bazel @@ -3,12 +3,6 @@ load(":toolchain.bzl", "git_toolchain") package(default_visibility = ["//visibility:public"]) -# Make source files available for distribution via pkg_npm -filegroup( - name = "files", - srcs = glob(["*"]), -) - toolchain_type(name = "toolchain_type") git_toolchain_alias(name = "current_git_toolchain") diff --git a/bazel/http-server/BUILD.bazel b/bazel/http-server/BUILD.bazel index 01bfd6923..7d0b29d85 100644 --- a/bazel/http-server/BUILD.bazel +++ b/bazel/http-server/BUILD.bazel @@ -5,12 +5,6 @@ package(default_visibility = ["//visibility:public"]) exports_files(["launcher_template.sh"]) -# Make source files available for distribution via pkg_npm -filegroup( - name = "files", - srcs = glob(["*"]), -) - ts_project( name = "server_lib", srcs = [ diff --git a/bazel/integration/tests/package_mappings/fake_pkg_srcs/BUILD.bazel b/bazel/integration/tests/package_mappings/fake_pkg_srcs/BUILD.bazel index b92ee6597..8e3a4128e 100644 --- a/bazel/integration/tests/package_mappings/fake_pkg_srcs/BUILD.bazel +++ b/bazel/integration/tests/package_mappings/fake_pkg_srcs/BUILD.bazel @@ -1,13 +1,12 @@ +load("@aspect_rules_js//npm:defs.bzl", "npm_package") load("@rules_pkg//:pkg.bzl", "pkg_tar") -load("//tools:defaults.bzl", "pkg_npm") -pkg_npm( +npm_package( name = "npm_package", srcs = [ "index.mjs", "package.json", ], - validate = False, ) pkg_tar( diff --git a/bazel/private/BUILD.bazel b/bazel/private/BUILD.bazel index 7baa46900..e69de29bb 100644 --- a/bazel/private/BUILD.bazel +++ b/bazel/private/BUILD.bazel @@ -1,7 +0,0 @@ -package(default_visibility = ["//visibility:public"]) - -# Make source files available for distribution via pkg_npm -filegroup( - name = "files", - srcs = glob(["*"]), -) diff --git a/bazel/remote-execution/BUILD.bazel b/bazel/remote-execution/BUILD.bazel index 864069201..77a899378 100644 --- a/bazel/remote-execution/BUILD.bazel +++ b/bazel/remote-execution/BUILD.bazel @@ -37,11 +37,3 @@ platform( exec_properties = ENABLE_NETWORK, parents = [":platform"], ) - -filegroup( - name = "files", - srcs = [ - "BUILD.bazel", - "index.bzl", - ], -) diff --git a/bazel/spec-bundling/BUILD.bazel b/bazel/spec-bundling/BUILD.bazel index 7baa46900..ffd0fb0cd 100644 --- a/bazel/spec-bundling/BUILD.bazel +++ b/bazel/spec-bundling/BUILD.bazel @@ -1,7 +1 @@ package(default_visibility = ["//visibility:public"]) - -# Make source files available for distribution via pkg_npm -filegroup( - name = "files", - srcs = glob(["*"]), -) diff --git a/bazel/ts_project/BUILD.bazel b/bazel/ts_project/BUILD.bazel index e25fbc468..ffd0fb0cd 100644 --- a/bazel/ts_project/BUILD.bazel +++ b/bazel/ts_project/BUILD.bazel @@ -1,9 +1 @@ package(default_visibility = ["//visibility:public"]) - -# Make source files available for distribution -filegroup( - name = "files", - srcs = glob(["*"]) + [ - "//bazel/ts_project/strict_deps:files", - ], -) diff --git a/bazel/ts_project/strict_deps/BUILD.bazel b/bazel/ts_project/strict_deps/BUILD.bazel index 8ca3bd0a4..b415b1634 100644 --- a/bazel/ts_project/strict_deps/BUILD.bazel +++ b/bazel/ts_project/strict_deps/BUILD.bazel @@ -3,12 +3,6 @@ load("@aspect_rules_ts//ts:defs.bzl", "ts_project") package(default_visibility = ["//visibility:public"]) -# Make source files available for distribution -filegroup( - name = "files", - srcs = glob(["*"]), -) - ts_project( name = "lib", srcs = glob(["*.mts"]), diff --git a/github-actions/BUILD.bazel b/github-actions/BUILD.bazel index 75c3ee31e..72a93befd 100644 --- a/github-actions/BUILD.bazel +++ b/github-actions/BUILD.bazel @@ -7,7 +7,7 @@ ts_config( src = "tsconfig.json", deps = [ "//:node_modules/@types/node", - "//:rjs-tsconfig", + "//:tsconfig", ], ) diff --git a/github-actions/bazel/configure-remote/BUILD.bazel b/github-actions/bazel/configure-remote/BUILD.bazel index b43341fcf..6d48ad47e 100644 --- a/github-actions/bazel/configure-remote/BUILD.bazel +++ b/github-actions/bazel/configure-remote/BUILD.bazel @@ -20,7 +20,7 @@ ts_project( js_binary( name = "encrypt", - data = [":setup-bazel-remote-exec_rjs"], + data = [":setup-bazel-remote-exec"], entry_point = ":encrypt.js", ) @@ -28,7 +28,7 @@ esbuild_checked_in( name = "configure-remote", srcs = [ ":gcp_token", - ":setup-bazel-remote-exec_rjs", + ":setup-bazel-remote-exec", ], config = { "loader": { diff --git a/github-actions/branch-manager/BUILD.bazel b/github-actions/branch-manager/BUILD.bazel index 12b1ef5bd..53336847d 100644 --- a/github-actions/branch-manager/BUILD.bazel +++ b/github-actions/branch-manager/BUILD.bazel @@ -17,15 +17,15 @@ ts_project( ":node_modules/@types/node", ":node_modules/typed-graphqlify", ":node_modules/undici", - "//github-actions:utils_rjs", - "//ng-dev/pr/common/labels:labels_rjs", + "//github-actions:utils", + "//ng-dev/pr/common/labels", ], ) esbuild_checked_in( name = "main", srcs = [ - ":lib_rjs", + ":lib", ], entry_point = "lib/main.ts", format = "esm", diff --git a/github-actions/browserstack/BUILD.bazel b/github-actions/browserstack/BUILD.bazel index 3e20b44e5..b61e680e8 100644 --- a/github-actions/browserstack/BUILD.bazel +++ b/github-actions/browserstack/BUILD.bazel @@ -27,7 +27,7 @@ js_binary( esbuild_checked_in( name = "set-browserstack-env", srcs = [ - ":browserstack_rjs", + ":browserstack", ":browserstack_token", ], config = { diff --git a/github-actions/feature-request/BUILD.bazel b/github-actions/feature-request/BUILD.bazel index dbefe0296..0c042f2f8 100644 --- a/github-actions/feature-request/BUILD.bazel +++ b/github-actions/feature-request/BUILD.bazel @@ -19,7 +19,7 @@ ts_project( ":node_modules/@octokit/rest", ":node_modules/@types/node", ":node_modules/undici", - "//github-actions:utils_rjs", + "//github-actions:utils", ], ) @@ -29,7 +29,7 @@ ts_project( srcs = glob(["lib/*.spec.ts"]), tsconfig = "//github-actions:tsconfig_test", deps = [ - ":lib_rjs", + ":lib", ":node_modules/@types/jasmine", ], ) @@ -37,14 +37,14 @@ ts_project( jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], ) esbuild_checked_in( name = "main", srcs = [ - ":lib_rjs", + ":lib", ], entry_point = "lib/main.ts", format = "esm", diff --git a/github-actions/google-internal-tests/BUILD.bazel b/github-actions/google-internal-tests/BUILD.bazel index b04d210f0..6fded7b48 100644 --- a/github-actions/google-internal-tests/BUILD.bazel +++ b/github-actions/google-internal-tests/BUILD.bazel @@ -15,14 +15,14 @@ ts_project( ":node_modules/@octokit/rest", ":node_modules/@types/node", ":node_modules/undici", - "//ng-dev/utils:g3_sync_config_rjs", + "//ng-dev/utils:g3_sync_config", ], ) esbuild_checked_in( name = "main", srcs = [ - ":lib_rjs", + ":lib", ], entry_point = "lib/main.ts", format = "esm", diff --git a/github-actions/org-file-sync/BUILD.bazel b/github-actions/org-file-sync/BUILD.bazel index d904f2220..87ec95bed 100644 --- a/github-actions/org-file-sync/BUILD.bazel +++ b/github-actions/org-file-sync/BUILD.bazel @@ -16,14 +16,14 @@ ts_project( ":node_modules/@octokit/types", ":node_modules/@types/node", ":node_modules/undici", - "//github-actions:utils_rjs", + "//github-actions:utils", ], ) esbuild_checked_in( name = "main", srcs = [ - ":lib_rjs", + ":lib", ], entry_point = "lib/main.ts", format = "esm", diff --git a/github-actions/post-approval-changes/BUILD.bazel b/github-actions/post-approval-changes/BUILD.bazel index a04e50360..bc57322e1 100644 --- a/github-actions/post-approval-changes/BUILD.bazel +++ b/github-actions/post-approval-changes/BUILD.bazel @@ -16,14 +16,14 @@ ts_project( ":node_modules/@octokit/webhooks-types", ":node_modules/@types/node", ":node_modules/undici", - "//github-actions:utils_rjs", + "//github-actions:utils", ], ) esbuild_checked_in( name = "main", srcs = [ - ":lib_rjs", + ":lib", ], entry_point = "lib/main.ts", format = "esm", diff --git a/github-actions/previews/pack-and-upload-artifact/BUILD.bazel b/github-actions/previews/pack-and-upload-artifact/BUILD.bazel index 71df835a7..bacbe3d25 100644 --- a/github-actions/previews/pack-and-upload-artifact/BUILD.bazel +++ b/github-actions/previews/pack-and-upload-artifact/BUILD.bazel @@ -11,14 +11,14 @@ ts_project( tsconfig = "//github-actions:tsconfig", deps = [ ":node_modules/@types/node", - "//github-actions/previews:constants_lib_rjs", + "//github-actions/previews:constants_lib", ], ) esbuild_checked_in( name = "inject-artifact-metadata", srcs = [ - ":lib_rjs", + ":lib", ], entry_point = "lib/inject-artifact-metadata.ts", format = "esm", diff --git a/github-actions/previews/upload-artifacts-to-firebase/BUILD.bazel b/github-actions/previews/upload-artifacts-to-firebase/BUILD.bazel index cca5be1dc..a2a805804 100644 --- a/github-actions/previews/upload-artifacts-to-firebase/BUILD.bazel +++ b/github-actions/previews/upload-artifacts-to-firebase/BUILD.bazel @@ -10,7 +10,7 @@ ts_project( deps = [ ":node_modules/@actions/core", ":node_modules/@types/node", - "//github-actions/previews:constants_lib_rjs", + "//github-actions/previews:constants_lib", ], ) @@ -27,7 +27,7 @@ ts_project( esbuild_checked_in( name = "fetch-workflow-artifact", srcs = [ - ":fetch_workflow_artifact_lib_rjs", + ":fetch_workflow_artifact_lib", ], entry_point = "lib/fetch-workflow-artifact.ts", format = "esm", @@ -38,7 +38,7 @@ esbuild_checked_in( esbuild_checked_in( name = "extract-artifact-metadata", srcs = [ - ":extract_artifact_metadata_lib_rjs", + ":extract_artifact_metadata_lib", ], entry_point = "lib/extract-artifact-metadata.ts", format = "esm", diff --git a/github-actions/pull-request-labeling/BUILD.bazel b/github-actions/pull-request-labeling/BUILD.bazel index 86efec7f5..49e79b68b 100644 --- a/github-actions/pull-request-labeling/BUILD.bazel +++ b/github-actions/pull-request-labeling/BUILD.bazel @@ -15,16 +15,16 @@ ts_project( ":node_modules/@octokit/rest", ":node_modules/@types/node", ":node_modules/undici", - "//github-actions:utils_rjs", - "//ng-dev/commit-message:commit-message_rjs", - "//ng-dev/pr/common/labels:labels_rjs", + "//github-actions:utils", + "//ng-dev/commit-message", + "//ng-dev/pr/common/labels", ], ) esbuild_checked_in( name = "main", srcs = [ - ":lib_rjs", + ":lib", ], entry_point = "lib/main.ts", format = "esm", diff --git a/github-actions/saucelabs/BUILD.bazel b/github-actions/saucelabs/BUILD.bazel index 768ee4bc5..d0d469fb6 100644 --- a/github-actions/saucelabs/BUILD.bazel +++ b/github-actions/saucelabs/BUILD.bazel @@ -27,7 +27,7 @@ js_binary( esbuild_checked_in( name = "set-saucelabs-env", srcs = [ - ":saucelabs_rjs", + ":saucelabs", ":saucelabs_token", ], config = { diff --git a/github-actions/unified-status-check/BUILD.bazel b/github-actions/unified-status-check/BUILD.bazel index e3be20b09..993ea8f1d 100644 --- a/github-actions/unified-status-check/BUILD.bazel +++ b/github-actions/unified-status-check/BUILD.bazel @@ -18,15 +18,15 @@ ts_project( ":node_modules/@types/node", ":node_modules/typed-graphqlify", ":node_modules/undici", - "//github-actions:utils_rjs", - "//ng-dev/pr/common/labels:labels_rjs", + "//github-actions:utils", + "//ng-dev/pr/common/labels", ], ) esbuild_checked_in( name = "main", srcs = [ - ":lib_rjs", + ":lib", ], entry_point = "lib/main.ts", format = "esm", diff --git a/lint-rules/stylelint/BUILD.bazel b/lint-rules/stylelint/BUILD.bazel deleted file mode 100644 index 638834a80..000000000 --- a/lint-rules/stylelint/BUILD.bazel +++ /dev/null @@ -1,20 +0,0 @@ -load("//tools:defaults.bzl", "ts_library") - -ts_library( - name = "lib", - srcs = glob(["*.ts"]), - # Note: stylelint rules need to be written in CommonJS. - devmode_module = "commonjs", - visibility = ["//:npm"], - deps = [ - "@npm//@types/node", - "@npm//stylelint", - "@npm//typescript", - ], -) - -filegroup( - name = "static_files", - srcs = ["ts-node-loader-rule.js"], - visibility = ["//:npm"], -) diff --git a/lint-rules/tslint/BUILD.bazel b/lint-rules/tslint/BUILD.bazel deleted file mode 100644 index ac3ecf486..000000000 --- a/lint-rules/tslint/BUILD.bazel +++ /dev/null @@ -1,19 +0,0 @@ -load("//tools:defaults.bzl", "ts_library") - -ts_library( - name = "lib", - srcs = glob(["*.ts"]), - # Note: TSLint rules need to be written in CommonJS. - devmode_module = "commonjs", - visibility = ["//:npm"], - deps = [ - "@npm//tslint", - "@npm//typescript", - ], -) - -filegroup( - name = "static_files", - srcs = ["tsNodeLoaderRule.js"], - visibility = ["//:npm"], -) diff --git a/ng-dev/BUILD.bazel b/ng-dev/BUILD.bazel index 6f352cceb..fc93141e2 100644 --- a/ng-dev/BUILD.bazel +++ b/ng-dev/BUILD.bazel @@ -49,26 +49,26 @@ ts_project( "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/yaml", "//ng-dev:node_modules/yargs", - "//ng-dev/ai:ai_rjs", - "//ng-dev/auth:auth_rjs", - "//ng-dev/caretaker:caretaker_rjs", - "//ng-dev/commit-message:commit-message_rjs", - "//ng-dev/format:format_rjs", - "//ng-dev/misc:misc_rjs", - "//ng-dev/ngbot:ngbot_rjs", - "//ng-dev/perf:perf_rjs", - "//ng-dev/pr:pr_rjs", - "//ng-dev/pr/common/labels:labels_rjs", - "//ng-dev/pr/config:config_rjs", - "//ng-dev/pullapprove:pullapprove_rjs", - "//ng-dev/release:release_rjs", - "//ng-dev/release/config:config_rjs", - "//ng-dev/release/precheck:precheck_rjs", - "//ng-dev/release/publish:publish_rjs", - "//ng-dev/release/stamping:stamping_rjs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/ts-circular-dependencies:ts-circular-dependencies_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/ai", + "//ng-dev/auth", + "//ng-dev/caretaker", + "//ng-dev/commit-message", + "//ng-dev/format", + "//ng-dev/misc", + "//ng-dev/ngbot", + "//ng-dev/perf", + "//ng-dev/pr", + "//ng-dev/pr/common/labels", + "//ng-dev/pr/config", + "//ng-dev/pullapprove", + "//ng-dev/release", + "//ng-dev/release/config", + "//ng-dev/release/precheck", + "//ng-dev/release/publish", + "//ng-dev/release/stamping", + "//ng-dev/release/versioning", + "//ng-dev/ts-circular-dependencies", + "//ng-dev/utils", ], ) @@ -113,21 +113,16 @@ const require = __cjsCompatRequire(import.meta.url); splitting = True, target = "node22", deps = [ - ":ng-dev_rjs", + ":ng-dev", ], ) -filegroup( - name = "static_files", - srcs = ["package.json"], -) - npm_package( name = "npm_package", srcs = [ "package.json", ":bundles", - ":ng-dev_rjs", + ":ng-dev", ":types", ], package = "@angular/ng-dev", diff --git a/ng-dev/ai/BUILD.bazel b/ng-dev/ai/BUILD.bazel index e12369dd8..99acb6d9c 100644 --- a/ng-dev/ai/BUILD.bazel +++ b/ng-dev/ai/BUILD.bazel @@ -5,9 +5,6 @@ ts_project( srcs = glob([ "**/*.ts", ]), - interop_deps = [ - "//ng-dev/utils", - ], visibility = ["//ng-dev:__subpackages__"], deps = [ "//ng-dev:node_modules/@google/genai", @@ -17,5 +14,6 @@ ts_project( "//ng-dev:node_modules/cli-progress", "//ng-dev:node_modules/fast-glob", "//ng-dev:node_modules/yargs", + "//ng-dev/utils", ], ) diff --git a/ng-dev/auth/BUILD.bazel b/ng-dev/auth/BUILD.bazel index a5dafc609..81a7f0def 100644 --- a/ng-dev/auth/BUILD.bazel +++ b/ng-dev/auth/BUILD.bazel @@ -9,7 +9,7 @@ ts_project( deps = [ "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/firebase", - "//ng-dev/auth/login:login_rjs", - "//ng-dev/auth/logout:logout_rjs", + "//ng-dev/auth/login", + "//ng-dev/auth/logout", ], ) diff --git a/ng-dev/auth/login/BUILD.bazel b/ng-dev/auth/login/BUILD.bazel index 7967b5c4e..8fc9bfd9c 100644 --- a/ng-dev/auth/login/BUILD.bazel +++ b/ng-dev/auth/login/BUILD.bazel @@ -5,13 +5,11 @@ ts_project( srcs = [ "cli.ts", ], - interop_deps = [ - "//ng-dev/utils", - ], visibility = ["//ng-dev/auth:__pkg__"], deps = [ "//ng-dev:node_modules/@types/node", "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/yargs", + "//ng-dev/utils", ], ) diff --git a/ng-dev/auth/logout/BUILD.bazel b/ng-dev/auth/logout/BUILD.bazel index 9d98a5157..9df6186c4 100644 --- a/ng-dev/auth/logout/BUILD.bazel +++ b/ng-dev/auth/logout/BUILD.bazel @@ -10,6 +10,6 @@ ts_project( "//ng-dev:node_modules/@types/node", "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/yargs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/utils", ], ) diff --git a/ng-dev/caretaker/BUILD.bazel b/ng-dev/caretaker/BUILD.bazel index 68cd3d082..772f2b1f5 100644 --- a/ng-dev/caretaker/BUILD.bazel +++ b/ng-dev/caretaker/BUILD.bazel @@ -16,9 +16,9 @@ ts_project( "//ng-dev:node_modules/typed-graphqlify", "//ng-dev:node_modules/yaml", "//ng-dev:node_modules/yargs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:g3_sync_config_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/release/versioning", + "//ng-dev/utils", + "//ng-dev/utils:g3_sync_config", ], ) @@ -27,20 +27,20 @@ ts_project( testonly = True, srcs = glob(["**/*.spec.ts"]), deps = [ - ":caretaker_rjs", + ":caretaker", "//ng-dev:node_modules/@types/jasmine", "//ng-dev:node_modules/@types/node", "//ng-dev:node_modules/@types/semver", "//ng-dev:node_modules/semver", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", - "//ng-dev/utils/testing:testing_rjs", + "//ng-dev/release/versioning", + "//ng-dev/utils", + "//ng-dev/utils/testing", ], ) jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], ) diff --git a/ng-dev/commit-message/BUILD.bazel b/ng-dev/commit-message/BUILD.bazel index d331ac8ba..ae2ebf7a9 100644 --- a/ng-dev/commit-message/BUILD.bazel +++ b/ng-dev/commit-message/BUILD.bazel @@ -18,7 +18,7 @@ ts_project( "//ng-dev:node_modules/conventional-commits-parser", "//ng-dev:node_modules/git-raw-commits", "//ng-dev:node_modules/yargs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/utils", ], ) @@ -27,16 +27,16 @@ ts_project( testonly = True, srcs = glob(["**/*.spec.ts"]), deps = [ - ":commit-message_rjs", + ":commit-message", "//ng-dev:node_modules/@types/events", "//ng-dev:node_modules/@types/jasmine", - "//ng-dev/utils:utils_rjs", + "//ng-dev/utils", ], ) jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], ) diff --git a/ng-dev/format/BUILD.bazel b/ng-dev/format/BUILD.bazel index 9666ac722..27df8a029 100644 --- a/ng-dev/format/BUILD.bazel +++ b/ng-dev/format/BUILD.bazel @@ -14,6 +14,6 @@ ts_project( "//ng-dev:node_modules/fast-glob", "//ng-dev:node_modules/multimatch", "//ng-dev:node_modules/yargs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/utils", ], ) diff --git a/ng-dev/misc/BUILD.bazel b/ng-dev/misc/BUILD.bazel index 48685a572..f8c1b0725 100644 --- a/ng-dev/misc/BUILD.bazel +++ b/ng-dev/misc/BUILD.bazel @@ -8,8 +8,8 @@ ts_project( "//ng-dev:node_modules/@types/node", "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/chalk", - "//ng-dev/release/build:build_rjs", - "//ng-dev/release/config:config_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/release/build", + "//ng-dev/release/config", + "//ng-dev/utils", ], ) diff --git a/ng-dev/ngbot/BUILD.bazel b/ng-dev/ngbot/BUILD.bazel index 027af5b9a..e7aab1736 100644 --- a/ng-dev/ngbot/BUILD.bazel +++ b/ng-dev/ngbot/BUILD.bazel @@ -12,6 +12,6 @@ ts_project( "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/yaml", "//ng-dev:node_modules/yargs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/utils", ], ) diff --git a/ng-dev/perf/BUILD.bazel b/ng-dev/perf/BUILD.bazel index f325b326b..f5af15449 100644 --- a/ng-dev/perf/BUILD.bazel +++ b/ng-dev/perf/BUILD.bazel @@ -6,6 +6,6 @@ ts_project( visibility = ["//ng-dev:__subpackages__"], deps = [ "//ng-dev:node_modules/@types/yargs", - "//ng-dev/perf/workflow:workflow_rjs", + "//ng-dev/perf/workflow", ], ) diff --git a/ng-dev/perf/workflow/BUILD.bazel b/ng-dev/perf/workflow/BUILD.bazel index d689df4e7..54d1ae507 100644 --- a/ng-dev/perf/workflow/BUILD.bazel +++ b/ng-dev/perf/workflow/BUILD.bazel @@ -9,6 +9,6 @@ ts_project( "//ng-dev:node_modules/@types/node", "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/yaml", - "//ng-dev/utils:utils_rjs", + "//ng-dev/utils", ], ) diff --git a/ng-dev/pr/BUILD.bazel b/ng-dev/pr/BUILD.bazel index a6ea48bc5..6eaa8244f 100644 --- a/ng-dev/pr/BUILD.bazel +++ b/ng-dev/pr/BUILD.bazel @@ -6,10 +6,10 @@ ts_project( visibility = ["//ng-dev:__subpackages__"], deps = [ "//ng-dev:node_modules/@types/yargs", - "//ng-dev/pr/check-target-branches:check-target-branches_rjs", - "//ng-dev/pr/checkout:checkout_rjs", - "//ng-dev/pr/discover-new-conflicts:discover-new-conflicts_rjs", - "//ng-dev/pr/merge:merge_rjs", - "//ng-dev/pr/rebase:rebase_rjs", + "//ng-dev/pr/check-target-branches", + "//ng-dev/pr/checkout", + "//ng-dev/pr/discover-new-conflicts", + "//ng-dev/pr/merge", + "//ng-dev/pr/rebase", ], ) diff --git a/ng-dev/pr/check-target-branches/BUILD.bazel b/ng-dev/pr/check-target-branches/BUILD.bazel index 25f6dff21..1ca7e424d 100644 --- a/ng-dev/pr/check-target-branches/BUILD.bazel +++ b/ng-dev/pr/check-target-branches/BUILD.bazel @@ -6,9 +6,9 @@ ts_project( visibility = ["//ng-dev:__subpackages__"], deps = [ "//ng-dev:node_modules/@types/yargs", - "//ng-dev/pr/common:common_rjs", - "//ng-dev/pr/config:config_rjs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/pr/common", + "//ng-dev/pr/config", + "//ng-dev/release/versioning", + "//ng-dev/utils", ], ) diff --git a/ng-dev/pr/checkout/BUILD.bazel b/ng-dev/pr/checkout/BUILD.bazel index 8dc3f2cca..5fb936f51 100755 --- a/ng-dev/pr/checkout/BUILD.bazel +++ b/ng-dev/pr/checkout/BUILD.bazel @@ -17,8 +17,8 @@ ts_project( deps = [ "//ng-dev:node_modules/@types/node", "//ng-dev:node_modules/@types/yargs", - "//ng-dev/pr/common:common_rjs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/pr/common", + "//ng-dev/release/versioning", + "//ng-dev/utils", ], ) diff --git a/ng-dev/pr/common/BUILD.bazel b/ng-dev/pr/common/BUILD.bazel index 963390731..55e4495e8 100644 --- a/ng-dev/pr/common/BUILD.bazel +++ b/ng-dev/pr/common/BUILD.bazel @@ -23,12 +23,12 @@ ts_project( "//ng-dev:node_modules/minimatch", "//ng-dev:node_modules/semver", "//ng-dev:node_modules/typed-graphqlify", - "//ng-dev/commit-message:commit-message_rjs", - "//ng-dev/pr/common/labels:labels_rjs", - "//ng-dev/pr/config:config_rjs", - "//ng-dev/release/config:config_rjs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:g3_sync_config_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/commit-message", + "//ng-dev/pr/common/labels", + "//ng-dev/pr/config", + "//ng-dev/release/config", + "//ng-dev/release/versioning", + "//ng-dev/utils", + "//ng-dev/utils:g3_sync_config", ], ) diff --git a/ng-dev/pr/common/labels/BUILD.bazel b/ng-dev/pr/common/labels/BUILD.bazel index 62ccb46b6..768e3f986 100644 --- a/ng-dev/pr/common/labels/BUILD.bazel +++ b/ng-dev/pr/common/labels/BUILD.bazel @@ -12,7 +12,7 @@ ts_project( "//ng-dev:__subpackages__", ], deps = [ - "//ng-dev/commit-message:commit-message_rjs", + "//ng-dev/commit-message", ], ) @@ -21,7 +21,7 @@ ts_project( testonly = True, srcs = glob(["*.spec.ts"]), deps = [ - ":labels_rjs", + ":labels", "//ng-dev:node_modules/@types/jasmine", ], ) @@ -29,6 +29,6 @@ ts_project( jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], ) diff --git a/ng-dev/pr/common/test/BUILD.bazel b/ng-dev/pr/common/test/BUILD.bazel index 353e589ee..f5815bb3a 100644 --- a/ng-dev/pr/common/test/BUILD.bazel +++ b/ng-dev/pr/common/test/BUILD.bazel @@ -19,19 +19,19 @@ ts_project( "//ng-dev:node_modules/nock", "//ng-dev:node_modules/semver", "//ng-dev:node_modules/yargs", - "//ng-dev/pr/common:common_rjs", - "//ng-dev/pr/common/labels:labels_rjs", - "//ng-dev/pr/config:config_rjs", - "//ng-dev/utils:g3_sync_config_rjs", - "//ng-dev/utils:utils_rjs", - "//ng-dev/utils/testing:testing_rjs", + "//ng-dev/pr/common", + "//ng-dev/pr/common/labels", + "//ng-dev/pr/config", + "//ng-dev/utils", + "//ng-dev/utils:g3_sync_config", + "//ng-dev/utils/testing", ], ) jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], env = { "GIT_BIN": "$(GIT_BIN_PATH)", diff --git a/ng-dev/pr/config/BUILD.bazel b/ng-dev/pr/config/BUILD.bazel index ed2227e7e..ae5810658 100644 --- a/ng-dev/pr/config/BUILD.bazel +++ b/ng-dev/pr/config/BUILD.bazel @@ -8,7 +8,7 @@ ts_project( "//ng-dev:__subpackages__", ], deps = [ - "//ng-dev/commit-message:commit-message_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/commit-message", + "//ng-dev/utils", ], ) diff --git a/ng-dev/pr/discover-new-conflicts/BUILD.bazel b/ng-dev/pr/discover-new-conflicts/BUILD.bazel index 7673978f7..b9c735f3d 100644 --- a/ng-dev/pr/discover-new-conflicts/BUILD.bazel +++ b/ng-dev/pr/discover-new-conflicts/BUILD.bazel @@ -11,7 +11,7 @@ ts_project( "//ng-dev:node_modules/@types/cli-progress", "//ng-dev:node_modules/@types/node", "//ng-dev:node_modules/@types/yargs", - "//ng-dev/pr/common:common_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/pr/common", + "//ng-dev/utils", ], ) diff --git a/ng-dev/pr/merge/BUILD.bazel b/ng-dev/pr/merge/BUILD.bazel index 2bb2fbf77..ee5935188 100644 --- a/ng-dev/pr/merge/BUILD.bazel +++ b/ng-dev/pr/merge/BUILD.bazel @@ -28,13 +28,13 @@ ts_project( "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/chalk", "//ng-dev:node_modules/typed-graphqlify", - "//ng-dev/commit-message:commit-message_rjs", - "//ng-dev/pr/common:common_rjs", - "//ng-dev/pr/common/labels:labels_rjs", - "//ng-dev/pr/config:config_rjs", - "//ng-dev/release/config:config_rjs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/commit-message", + "//ng-dev/pr/common", + "//ng-dev/pr/common/labels", + "//ng-dev/pr/config", + "//ng-dev/release/config", + "//ng-dev/release/versioning", + "//ng-dev/utils", ], ) @@ -43,19 +43,19 @@ ts_project( testonly = True, srcs = glob(["**/*.spec.ts"]), deps = [ - ":merge_rjs", + ":merge", "//ng-dev:node_modules/nock", - "//ng-dev/pr/common:common_rjs", - "//ng-dev/release/config:config_rjs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", - "//ng-dev/utils/testing:testing_rjs", + "//ng-dev/pr/common", + "//ng-dev/release/config", + "//ng-dev/release/versioning", + "//ng-dev/utils", + "//ng-dev/utils/testing", ], ) jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], ) diff --git a/ng-dev/pr/rebase/BUILD.bazel b/ng-dev/pr/rebase/BUILD.bazel index 6c5df96da..dd231a0cb 100644 --- a/ng-dev/pr/rebase/BUILD.bazel +++ b/ng-dev/pr/rebase/BUILD.bazel @@ -17,8 +17,8 @@ ts_project( "//ng-dev:node_modules/conventional-commits-parser", "//ng-dev:node_modules/typed-graphqlify", "//ng-dev:node_modules/yargs", - "//ng-dev/commit-message:commit-message_rjs", - "//ng-dev/pr/common:common_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/commit-message", + "//ng-dev/pr/common", + "//ng-dev/utils", ], ) diff --git a/ng-dev/pullapprove/BUILD.bazel b/ng-dev/pullapprove/BUILD.bazel index 2bd55a757..0920c0271 100644 --- a/ng-dev/pullapprove/BUILD.bazel +++ b/ng-dev/pullapprove/BUILD.bazel @@ -21,7 +21,7 @@ ts_project( "//ng-dev:node_modules/minimatch", "//ng-dev:node_modules/yaml", "//ng-dev:node_modules/yargs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/utils", ], ) @@ -32,7 +32,7 @@ ts_project( ["*.spec.ts"], ), deps = [ - ":pullapprove_rjs", + ":pullapprove", "//ng-dev:node_modules/@types/jasmine", ], ) @@ -40,6 +40,6 @@ ts_project( jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], ) diff --git a/ng-dev/release/BUILD.bazel b/ng-dev/release/BUILD.bazel index ad1d13f1f..a2f53a7a1 100644 --- a/ng-dev/release/BUILD.bazel +++ b/ng-dev/release/BUILD.bazel @@ -10,14 +10,14 @@ ts_project( "//ng-dev:node_modules/@types/node", "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/yargs", - "//ng-dev/release/build:build_rjs", - "//ng-dev/release/info:info_rjs", - "//ng-dev/release/notes:notes_rjs", - "//ng-dev/release/npm-dist-tag:npm-dist-tag_rjs", - "//ng-dev/release/precheck:precheck_rjs", - "//ng-dev/release/publish:publish_rjs", - "//ng-dev/release/set-dist-tag:set-dist-tag_rjs", - "//ng-dev/release/stamping:stamping_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/release/build", + "//ng-dev/release/info", + "//ng-dev/release/notes", + "//ng-dev/release/npm-dist-tag", + "//ng-dev/release/precheck", + "//ng-dev/release/publish", + "//ng-dev/release/set-dist-tag", + "//ng-dev/release/stamping", + "//ng-dev/utils", ], ) diff --git a/ng-dev/release/build/BUILD.bazel b/ng-dev/release/build/BUILD.bazel index ceb327b71..407b2ed7a 100644 --- a/ng-dev/release/build/BUILD.bazel +++ b/ng-dev/release/build/BUILD.bazel @@ -20,8 +20,8 @@ ts_project( deps = [ "//ng-dev:node_modules/@types/node", "//ng-dev:node_modules/@types/yargs", - "//ng-dev/release/config:config_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/release/config", + "//ng-dev/utils", ], ) @@ -32,17 +32,17 @@ ts_project( "*.spec.ts", ]), deps = [ - ":build_rjs", + ":build", "//ng-dev:node_modules/@types/jasmine", "//ng-dev:node_modules/@types/node", - "//ng-dev/release/config:config_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/release/config", + "//ng-dev/utils", ], ) jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], ) diff --git a/ng-dev/release/config/BUILD.bazel b/ng-dev/release/config/BUILD.bazel index 6b6760ba7..8f802b3da 100644 --- a/ng-dev/release/config/BUILD.bazel +++ b/ng-dev/release/config/BUILD.bazel @@ -12,7 +12,7 @@ ts_project( deps = [ "//ng-dev:node_modules/@types/semver", "//ng-dev:node_modules/semver", - "//ng-dev/commit-message:commit-message_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/commit-message", + "//ng-dev/utils", ], ) diff --git a/ng-dev/release/info/BUILD.bazel b/ng-dev/release/info/BUILD.bazel index 731a0e54e..40bc4b42c 100644 --- a/ng-dev/release/info/BUILD.bazel +++ b/ng-dev/release/info/BUILD.bazel @@ -7,8 +7,8 @@ ts_project( deps = [ "//ng-dev:node_modules/@types/node", "//ng-dev:node_modules/@types/yargs", - "//ng-dev/release/config:config_rjs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/release/config", + "//ng-dev/release/versioning", + "//ng-dev/utils", ], ) diff --git a/ng-dev/release/notes/BUILD.bazel b/ng-dev/release/notes/BUILD.bazel index 1182fa96e..a6228fd9a 100644 --- a/ng-dev/release/notes/BUILD.bazel +++ b/ng-dev/release/notes/BUILD.bazel @@ -17,11 +17,11 @@ ts_project( "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/ejs", "//ng-dev:node_modules/semver", - "//ng-dev/commit-message:commit-message_rjs", - "//ng-dev/format:format_rjs", - "//ng-dev/release/config:config_rjs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/commit-message", + "//ng-dev/format", + "//ng-dev/release/config", + "//ng-dev/release/versioning", + "//ng-dev/utils", ], ) @@ -30,19 +30,19 @@ ts_project( testonly = True, srcs = glob(["**/*.spec.ts"]), deps = [ - ":notes_rjs", + ":notes", "//ng-dev:node_modules/@types/jasmine", "//ng-dev:node_modules/@types/node", "//ng-dev:node_modules/@types/semver", "//ng-dev:node_modules/semver", - "//ng-dev/utils:utils_rjs", - "//ng-dev/utils/testing:testing_rjs", + "//ng-dev/utils", + "//ng-dev/utils/testing", ], ) jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], ) diff --git a/ng-dev/release/npm-dist-tag/BUILD.bazel b/ng-dev/release/npm-dist-tag/BUILD.bazel index 5926d303d..ec1dbd773 100644 --- a/ng-dev/release/npm-dist-tag/BUILD.bazel +++ b/ng-dev/release/npm-dist-tag/BUILD.bazel @@ -10,7 +10,7 @@ ts_project( "//ng-dev:node_modules/@types/node", "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/yargs", - "//ng-dev/release/npm-dist-tag/delete:delete_rjs", - "//ng-dev/release/npm-dist-tag/set:set_rjs", + "//ng-dev/release/npm-dist-tag/delete", + "//ng-dev/release/npm-dist-tag/set", ], ) diff --git a/ng-dev/release/npm-dist-tag/delete/BUILD.bazel b/ng-dev/release/npm-dist-tag/delete/BUILD.bazel index f00e855c9..2bb6f625a 100644 --- a/ng-dev/release/npm-dist-tag/delete/BUILD.bazel +++ b/ng-dev/release/npm-dist-tag/delete/BUILD.bazel @@ -14,9 +14,9 @@ ts_project( "//ng-dev:node_modules/@types/semver", "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/semver", - "//ng-dev/release/config:config_rjs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/release/config", + "//ng-dev/release/versioning", + "//ng-dev/utils", ], ) @@ -27,19 +27,19 @@ ts_project( "*.spec.ts", ]), deps = [ - ":delete_rjs", + ":delete", "//ng-dev:node_modules/@types/jasmine", "//ng-dev:node_modules/@types/node", - "//ng-dev/release/config:config_rjs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", - "//ng-dev/utils/testing:testing_rjs", + "//ng-dev/release/config", + "//ng-dev/release/versioning", + "//ng-dev/utils", + "//ng-dev/utils/testing", ], ) jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], ) diff --git a/ng-dev/release/npm-dist-tag/set/BUILD.bazel b/ng-dev/release/npm-dist-tag/set/BUILD.bazel index e37f53c2b..ea2a8414c 100644 --- a/ng-dev/release/npm-dist-tag/set/BUILD.bazel +++ b/ng-dev/release/npm-dist-tag/set/BUILD.bazel @@ -14,9 +14,9 @@ ts_project( "//ng-dev:node_modules/@types/semver", "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/semver", - "//ng-dev/release/config:config_rjs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/release/config", + "//ng-dev/release/versioning", + "//ng-dev/utils", ], ) @@ -27,19 +27,19 @@ ts_project( "*.spec.ts", ]), deps = [ - ":set_rjs", + ":set", "//ng-dev:node_modules/@types/jasmine", "//ng-dev:node_modules/@types/node", - "//ng-dev/release/config:config_rjs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", - "//ng-dev/utils/testing:testing_rjs", + "//ng-dev/release/config", + "//ng-dev/release/versioning", + "//ng-dev/utils", + "//ng-dev/utils/testing", ], ) jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], ) diff --git a/ng-dev/release/precheck/BUILD.bazel b/ng-dev/release/precheck/BUILD.bazel index 15e6c6354..6c1d42925 100644 --- a/ng-dev/release/precheck/BUILD.bazel +++ b/ng-dev/release/precheck/BUILD.bazel @@ -14,8 +14,8 @@ ts_project( "//ng-dev:node_modules/@types/semver", "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/semver", - "//ng-dev/release/config:config_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/release/config", + "//ng-dev/utils", ], ) @@ -26,19 +26,19 @@ ts_project( "*.spec.ts", ]), deps = [ - ":precheck_rjs", + ":precheck", "//ng-dev:node_modules/@types/jasmine", "//ng-dev:node_modules/@types/node", "//ng-dev:node_modules/@types/semver", "//ng-dev:node_modules/semver", - "//ng-dev/release/config:config_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/release/config", + "//ng-dev/utils", ], ) jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], ) diff --git a/ng-dev/release/publish/BUILD.bazel b/ng-dev/release/publish/BUILD.bazel index 0b37510fe..1a698bedd 100644 --- a/ng-dev/release/publish/BUILD.bazel +++ b/ng-dev/release/publish/BUILD.bazel @@ -18,15 +18,15 @@ ts_project( "//ng-dev:node_modules/folder-hash", "//ng-dev:node_modules/semver", "//ng-dev:node_modules/typed-graphqlify", - "//ng-dev/commit-message:commit-message_rjs", - "//ng-dev/pr/common/labels:labels_rjs", - "//ng-dev/pr/merge:merge_rjs", - "//ng-dev/release/build:build_rjs", - "//ng-dev/release/config:config_rjs", - "//ng-dev/release/info:info_rjs", - "//ng-dev/release/notes:notes_rjs", - "//ng-dev/release/precheck:precheck_rjs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/commit-message", + "//ng-dev/pr/common/labels", + "//ng-dev/pr/merge", + "//ng-dev/release/build", + "//ng-dev/release/config", + "//ng-dev/release/info", + "//ng-dev/release/notes", + "//ng-dev/release/precheck", + "//ng-dev/release/versioning", + "//ng-dev/utils", ], ) diff --git a/ng-dev/release/publish/test/BUILD.bazel b/ng-dev/release/publish/test/BUILD.bazel index f3930f373..af27104f8 100644 --- a/ng-dev/release/publish/test/BUILD.bazel +++ b/ng-dev/release/publish/test/BUILD.bazel @@ -19,20 +19,20 @@ ts_project( "//ng-dev:node_modules/nock", "//ng-dev:node_modules/semver", "//ng-dev:node_modules/yargs", - "//ng-dev/commit-message:commit-message_rjs", - "//ng-dev/release/config:config_rjs", - "//ng-dev/release/notes:notes_rjs", - "//ng-dev/release/publish:publish_rjs", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", - "//ng-dev/utils/testing:testing_rjs", + "//ng-dev/commit-message", + "//ng-dev/release/config", + "//ng-dev/release/notes", + "//ng-dev/release/publish", + "//ng-dev/release/versioning", + "//ng-dev/utils", + "//ng-dev/utils/testing", ], ) jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], env = { "GIT_BIN": "$(GIT_BIN_PATH)", diff --git a/ng-dev/release/set-dist-tag/BUILD.bazel b/ng-dev/release/set-dist-tag/BUILD.bazel index 218a7d0b3..2b6091973 100644 --- a/ng-dev/release/set-dist-tag/BUILD.bazel +++ b/ng-dev/release/set-dist-tag/BUILD.bazel @@ -5,6 +5,6 @@ ts_project( srcs = glob(["**/*.ts"]), visibility = ["//ng-dev:__subpackages__"], deps = [ - "//ng-dev/release/npm-dist-tag/set:set_rjs", + "//ng-dev/release/npm-dist-tag/set", ], ) diff --git a/ng-dev/release/stamping/BUILD.bazel b/ng-dev/release/stamping/BUILD.bazel index 84a2fed64..eeae23f39 100644 --- a/ng-dev/release/stamping/BUILD.bazel +++ b/ng-dev/release/stamping/BUILD.bazel @@ -12,7 +12,7 @@ ts_project( "//ng-dev:node_modules/@types/semver", "//ng-dev:node_modules/@types/yargs", "//ng-dev:node_modules/semver", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/release/versioning", + "//ng-dev/utils", ], ) diff --git a/ng-dev/release/versioning/BUILD.bazel b/ng-dev/release/versioning/BUILD.bazel index c37a61d53..634a6505d 100644 --- a/ng-dev/release/versioning/BUILD.bazel +++ b/ng-dev/release/versioning/BUILD.bazel @@ -9,7 +9,7 @@ ts_project( deps = [ "//ng-dev:node_modules/@types/semver", "//ng-dev:node_modules/semver", - "//ng-dev/release/config:config_rjs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/release/config", + "//ng-dev/utils", ], ) diff --git a/ng-dev/release/versioning/test/BUILD.bazel b/ng-dev/release/versioning/test/BUILD.bazel index d4386df26..d2d5e1f20 100644 --- a/ng-dev/release/versioning/test/BUILD.bazel +++ b/ng-dev/release/versioning/test/BUILD.bazel @@ -9,15 +9,15 @@ ts_project( deps = [ "//ng-dev:node_modules/@types/jasmine", "//ng-dev:node_modules/nock", - "//ng-dev/release/versioning:versioning_rjs", - "//ng-dev/utils:utils_rjs", - "//ng-dev/utils/testing:testing_rjs", + "//ng-dev/release/versioning", + "//ng-dev/utils", + "//ng-dev/utils/testing", ], ) jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], ) diff --git a/ng-dev/ts-circular-dependencies/BUILD.bazel b/ng-dev/ts-circular-dependencies/BUILD.bazel index 2d30acf61..9c00f7022 100644 --- a/ng-dev/ts-circular-dependencies/BUILD.bazel +++ b/ng-dev/ts-circular-dependencies/BUILD.bazel @@ -10,6 +10,6 @@ ts_project( "//ng-dev:node_modules/chalk", "//ng-dev:node_modules/fast-glob", "//ng-dev:node_modules/typescript", - "//ng-dev/utils:utils_rjs", + "//ng-dev/utils", ], ) diff --git a/ng-dev/utils/BUILD.bazel b/ng-dev/utils/BUILD.bazel index a10376f37..bb3e78269 100644 --- a/ng-dev/utils/BUILD.bazel +++ b/ng-dev/utils/BUILD.bazel @@ -36,11 +36,10 @@ ts_project( "//github-actions/google-internal-tests:__subpackages__", "//github-actions/slash-commands/lib:__subpackages__", "//ng-dev:__subpackages__", - "//tools/jasmine:__pkg__", ], deps = [ - ":config_cache_rjs", - ":g3_sync_config_rjs", + ":config_cache", + ":g3_sync_config", "//ng-dev:node_modules/@actions/core", "//ng-dev:node_modules/@inquirer/prompts", "//ng-dev:node_modules/@octokit/auth-app", @@ -73,7 +72,4 @@ ts_project( ts_project( name = "config_cache", srcs = ["config-cache.ts"], - visibility = [ - "//tools/jasmine:__pkg__", - ], ) diff --git a/ng-dev/utils/test/BUILD.bazel b/ng-dev/utils/test/BUILD.bazel index 8cfda7439..9289be00f 100644 --- a/ng-dev/utils/test/BUILD.bazel +++ b/ng-dev/utils/test/BUILD.bazel @@ -9,15 +9,15 @@ ts_project( deps = [ "//ng-dev:node_modules/@types/jasmine", "//ng-dev:node_modules/@types/node", - "//ng-dev/utils:utils_rjs", - "//ng-dev/utils/testing:testing_rjs", + "//ng-dev/utils", + "//ng-dev/utils/testing", ], ) jasmine_test( name = "test", data = [ - ":test_lib_rjs", + ":test_lib", ], shard_count = 4, ) diff --git a/ng-dev/utils/testing/BUILD.bazel b/ng-dev/utils/testing/BUILD.bazel index 137682ceb..956891e84 100644 --- a/ng-dev/utils/testing/BUILD.bazel +++ b/ng-dev/utils/testing/BUILD.bazel @@ -11,7 +11,7 @@ ts_project( "//ng-dev:__subpackages__", ], deps = [ - ":bazel-env_rjs", + ":bazel-env", "//ng-dev:node_modules/@octokit/plugin-rest-endpoint-methods", "//ng-dev:node_modules/@types/jasmine", "//ng-dev:node_modules/@types/node", @@ -20,7 +20,7 @@ ts_project( "//ng-dev:node_modules/nock", "//ng-dev:node_modules/semver", "//ng-dev:node_modules/yargs", - "//ng-dev/utils:utils_rjs", + "//ng-dev/utils", ], ) @@ -31,7 +31,6 @@ ts_project( ], visibility = [ "//ng-dev/utils/testing:__subpackages__", - "//tools/jasmine:__subpackages__", ], deps = [ "//ng-dev:node_modules/@types/node", diff --git a/package.bzl b/package.bzl index 1d5a78ce6..1bbc010ce 100644 --- a/package.bzl +++ b/package.bzl @@ -26,19 +26,3 @@ NPM_PACKAGE_SUBSTITUTIONS = select({ "//tools:stamp": dict(basePackageSubstitutions, **stampSubstitutions), "//conditions:default": dict(basePackageSubstitutions, **noStampSubstitutions), }) - -# These packages are allowed to use macros from `defaults.bzl`. This is a -# little safety improvement to avoid accidentally relying on the defaults -# which are not available when the dev-infra tooling is consumed. -BZL_DEFAULTS_ALLOW_PACKAGES = [ - ".github/local-actions", - "", - "apps", - "bazel/api-golden", - "github-actions", - "ng-dev", - "tools", - "lint-rules/tslint", - "lint-rules/stylelint", - "docs", -] diff --git a/package.json b/package.json index 9d6b8ceee..69dd3cdf8 100644 --- a/package.json +++ b/package.json @@ -18,6 +18,8 @@ "packageManager": "yarn@4.9.1", "dependencies": { "@angular/build": "20.0.0", + "@angular/cdk": "20.0.0", + "@angular/material": "20.0.0", "@babel/core": "^7.16.0", "@babel/plugin-transform-async-generator-functions": "^7.26.8", "@bazel/buildifier": "8.2.1", @@ -54,7 +56,6 @@ "@actions/github": "^6.0.0", "@angular/animations": "20.0.0", "@angular/bazel": "14.1.0-next.2", - "@angular/cdk": "20.0.0", "@angular/cli": "20.0.0", "@angular/common": "20.0.0", "@angular/compiler": "20.0.0", @@ -62,7 +63,6 @@ "@angular/core": "20.0.0", "@angular/fire": "^20.0.0-rc", "@angular/forms": "20.0.0", - "@angular/material": "20.0.0", "@angular/platform-browser": "20.0.0", "@angular/platform-browser-dynamic": "20.0.0", "@angular/router": "20.0.0", @@ -158,5 +158,10 @@ "re2": { "built": false } + }, + "pnpm": { + "onlyBuiltDependencies": [ + "firebase-functions" + ] } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f02061369..c78125155 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -4,6 +4,9 @@ settings: autoInstallPeers: false excludeLinksFromLockfile: false +onlyBuiltDependencies: + - firebase-functions + importers: .: @@ -11,6 +14,12 @@ importers: '@angular/build': specifier: 20.0.0 version: 20.0.0(@angular/compiler-cli@20.0.0)(@angular/compiler@20.0.0)(@angular/core@20.0.0)(@angular/platform-browser@20.0.0)(@types/node@20.19.9)(karma@6.4.4)(supports-color@10.1.0)(terser@5.43.1)(tslib@2.8.1)(tsx@4.20.3)(typescript@5.8.3)(yaml@2.8.0) + '@angular/cdk': + specifier: 20.0.0 + version: 20.0.0(@angular/common@20.0.0)(@angular/core@20.0.0)(rxjs@7.8.2) + '@angular/material': + specifier: 20.0.0 + version: 20.0.0(@angular/cdk@20.0.0)(@angular/common@20.0.0)(@angular/core@20.0.0)(@angular/forms@20.0.0)(@angular/platform-browser@20.0.0)(rxjs@7.8.2) '@babel/core': specifier: ^7.16.0 version: 7.28.0(supports-color@10.1.0) @@ -114,9 +123,6 @@ importers: '@angular/bazel': specifier: 14.1.0-next.2 version: 14.1.0-next.2(@angular/compiler-cli@20.0.0)(@bazel/concatjs@5.8.1)(@rollup/plugin-commonjs@28.0.6)(@rollup/plugin-node-resolve@16.0.1)(@types/node@20.19.9)(terser@5.43.1)(typescript@5.8.3) - '@angular/cdk': - specifier: 20.0.0 - version: 20.0.0(@angular/common@20.0.0)(@angular/core@20.0.0)(rxjs@7.8.2) '@angular/cli': specifier: 20.0.0 version: 20.0.0(@types/node@20.19.9)(supports-color@10.1.0) @@ -138,9 +144,6 @@ importers: '@angular/forms': specifier: 20.0.0 version: 20.0.0(@angular/common@20.0.0)(@angular/core@20.0.0)(@angular/platform-browser@20.0.0)(rxjs@7.8.2) - '@angular/material': - specifier: 20.0.0 - version: 20.0.0(@angular/cdk@20.0.0)(@angular/common@20.0.0)(@angular/core@20.0.0)(@angular/forms@20.0.0)(@angular/platform-browser@20.0.0)(rxjs@7.8.2) '@angular/platform-browser': specifier: 20.0.0 version: 20.0.0(@angular/animations@20.0.0)(@angular/common@20.0.0)(@angular/core@20.0.0) @@ -1225,7 +1228,7 @@ packages: parse5: 7.3.0 rxjs: 7.8.2 tslib: 2.8.1 - dev: true + dev: false /@angular/cli@20.0.0(@types/node@20.19.9)(supports-color@10.1.0): resolution: {integrity: sha512-k9EDaaLYTMWkBbayUh6Tf0PJ+E0e6jRPrjOSPsOJHRh+S5BsNdLIsKJmThGXkq2wnD35+2CKPy9UQyvfaIA5KQ==} @@ -1385,7 +1388,6 @@ packages: '@angular/platform-browser': 20.0.0(@angular/animations@20.0.0)(@angular/common@20.0.0)(@angular/core@20.0.0) rxjs: 7.8.2 tslib: 2.8.1 - dev: true /@angular/material@20.0.0(@angular/cdk@20.0.0)(@angular/common@20.0.0)(@angular/core@20.0.0)(@angular/forms@20.0.0)(@angular/platform-browser@20.0.0)(rxjs@7.8.2): resolution: {integrity: sha512-uhSICVswGHwLuQg0Cn9q9ppdEBhpJDdW5FEotiVqjfPXjp/S6k7m/Ho8BNbDLdJNuMjF3uypc+tgzJIO+SHIOw==} @@ -1404,7 +1406,7 @@ packages: '@angular/platform-browser': 20.0.0(@angular/animations@20.0.0)(@angular/common@20.0.0)(@angular/core@20.0.0) rxjs: 7.8.2 tslib: 2.8.1 - dev: true + dev: false /@angular/platform-browser-dynamic@20.0.0(@angular/common@20.0.0)(@angular/compiler@20.0.0)(@angular/core@20.0.0)(@angular/platform-browser@20.0.0): resolution: {integrity: sha512-AACq3Ijuq59SdLDmfxWU8hYlo8O4Br9OHWNAga2W0X6p/7HlpeZZVdTlb/KGVYRKJvGpgSB10QYlRPfm215q9Q==} @@ -1793,7 +1795,6 @@ packages: /@bazel/concatjs@5.8.1(karma-chrome-launcher@3.2.0)(karma-firefox-launcher@2.1.3)(karma-jasmine@5.1.0)(karma-requirejs@1.1.0)(karma-sourcemap-loader@0.4.0)(karma@6.4.4)(typescript@5.8.3): resolution: {integrity: sha512-TkARsNUxgi3bjFeGwIGlffmQglNhuR9qK9uE7uKhdBZvQE5caAWVCjYiMTzo3viKDhwKn5QNRcHY5huuJMVFfA==} hasBin: true - requiresBuild: true peerDependencies: karma: '>=4.0.0' karma-chrome-launcher: '>=2.0.0' @@ -1817,7 +1818,6 @@ packages: /@bazel/esbuild@5.8.1: resolution: {integrity: sha512-8k4LL8P3ivCnFeBOcjiFxL8U+M5VtEGuOyIqm2hfEiP8xDWsZLS7YQ7KhshKJy7Elh2dlK9oGgMtl0D/x9kxxg==} - requiresBuild: true dev: false /@bazel/ibazel@0.25.0: @@ -1828,7 +1828,6 @@ packages: /@bazel/jasmine@5.8.1(jasmine-core@5.9.0)(jasmine@5.9.0): resolution: {integrity: sha512-052veW5EbJRH+5hL4l9Sf99bTmdKQ5WXXMF0QiBOZcA3ZHYMAaKfYNO+brutiWoX6FrBloiskLrMzF8OiHBqyw==} hasBin: true - requiresBuild: true peerDependencies: jasmine: '>=2.99.0' jasmine-core: '>=2.99.0' @@ -1841,7 +1840,6 @@ packages: /@bazel/protractor@5.8.1(protractor@7.0.0): resolution: {integrity: sha512-6JpP4uQLVRu3m0GrpexDjICKK8YJW/9voc8rZFQxVf3sm8yNjapUVN/b/PBAwua+nDY3uMe3W9aHgStZFOST0A==} - requiresBuild: true peerDependencies: protractor: '>=5.0.0' dependencies: @@ -1855,7 +1853,6 @@ packages: /@bazel/terser@5.8.1(terser@5.43.1): resolution: {integrity: sha512-TPjSDhw1pSZt9P2hd/22IJwl8KCZiJL+u2gB5mghBTCFDVdC5Dgsx135pFtvlqc6LjjOvd3s6dzcQr0YJo2HSg==} hasBin: true - requiresBuild: true peerDependencies: terser: '>=4.0.0 <5.9.0' dependencies: @@ -1865,7 +1862,6 @@ packages: /@bazel/typescript@5.8.1(typescript@5.8.3): resolution: {integrity: sha512-NAJ8WQHZL1WE1YmRoCrq/1hhG15Mvy/viWh6TkvFnBeEhNUiQUsA5GYyhU1ztnBIYW03nATO3vwhAEfO7Q0U5g==} hasBin: true - requiresBuild: true peerDependencies: typescript: '>=3.0.0' dependencies: @@ -1993,7 +1989,6 @@ packages: engines: {node: '>=18'} cpu: [ppc64] os: [aix] - requiresBuild: true dev: false optional: true @@ -2002,7 +1997,6 @@ packages: engines: {node: '>=18'} cpu: [ppc64] os: [aix] - requiresBuild: true optional: true /@esbuild/android-arm64@0.25.5: @@ -2010,7 +2004,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [android] - requiresBuild: true dev: false optional: true @@ -2019,7 +2012,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [android] - requiresBuild: true optional: true /@esbuild/android-arm@0.25.5: @@ -2027,7 +2019,6 @@ packages: engines: {node: '>=18'} cpu: [arm] os: [android] - requiresBuild: true dev: false optional: true @@ -2036,7 +2027,6 @@ packages: engines: {node: '>=18'} cpu: [arm] os: [android] - requiresBuild: true optional: true /@esbuild/android-x64@0.25.5: @@ -2044,7 +2034,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [android] - requiresBuild: true dev: false optional: true @@ -2053,7 +2042,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [android] - requiresBuild: true optional: true /@esbuild/darwin-arm64@0.25.5: @@ -2061,7 +2049,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [darwin] - requiresBuild: true dev: false optional: true @@ -2070,7 +2057,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [darwin] - requiresBuild: true optional: true /@esbuild/darwin-x64@0.25.5: @@ -2078,7 +2064,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [darwin] - requiresBuild: true dev: false optional: true @@ -2087,7 +2072,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [darwin] - requiresBuild: true optional: true /@esbuild/freebsd-arm64@0.25.5: @@ -2095,7 +2079,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [freebsd] - requiresBuild: true dev: false optional: true @@ -2104,7 +2087,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [freebsd] - requiresBuild: true optional: true /@esbuild/freebsd-x64@0.25.5: @@ -2112,7 +2094,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [freebsd] - requiresBuild: true dev: false optional: true @@ -2121,7 +2102,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [freebsd] - requiresBuild: true optional: true /@esbuild/linux-arm64@0.25.5: @@ -2129,7 +2109,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [linux] - requiresBuild: true dev: false optional: true @@ -2138,7 +2117,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [linux] - requiresBuild: true optional: true /@esbuild/linux-arm@0.25.5: @@ -2146,7 +2124,6 @@ packages: engines: {node: '>=18'} cpu: [arm] os: [linux] - requiresBuild: true dev: false optional: true @@ -2155,7 +2132,6 @@ packages: engines: {node: '>=18'} cpu: [arm] os: [linux] - requiresBuild: true optional: true /@esbuild/linux-ia32@0.25.5: @@ -2163,7 +2139,6 @@ packages: engines: {node: '>=18'} cpu: [ia32] os: [linux] - requiresBuild: true dev: false optional: true @@ -2172,7 +2147,6 @@ packages: engines: {node: '>=18'} cpu: [ia32] os: [linux] - requiresBuild: true optional: true /@esbuild/linux-loong64@0.25.5: @@ -2180,7 +2154,6 @@ packages: engines: {node: '>=18'} cpu: [loong64] os: [linux] - requiresBuild: true dev: false optional: true @@ -2189,7 +2162,6 @@ packages: engines: {node: '>=18'} cpu: [loong64] os: [linux] - requiresBuild: true optional: true /@esbuild/linux-mips64el@0.25.5: @@ -2197,7 +2169,6 @@ packages: engines: {node: '>=18'} cpu: [mips64el] os: [linux] - requiresBuild: true dev: false optional: true @@ -2206,7 +2177,6 @@ packages: engines: {node: '>=18'} cpu: [mips64el] os: [linux] - requiresBuild: true optional: true /@esbuild/linux-ppc64@0.25.5: @@ -2214,7 +2184,6 @@ packages: engines: {node: '>=18'} cpu: [ppc64] os: [linux] - requiresBuild: true dev: false optional: true @@ -2223,7 +2192,6 @@ packages: engines: {node: '>=18'} cpu: [ppc64] os: [linux] - requiresBuild: true optional: true /@esbuild/linux-riscv64@0.25.5: @@ -2231,7 +2199,6 @@ packages: engines: {node: '>=18'} cpu: [riscv64] os: [linux] - requiresBuild: true dev: false optional: true @@ -2240,7 +2207,6 @@ packages: engines: {node: '>=18'} cpu: [riscv64] os: [linux] - requiresBuild: true optional: true /@esbuild/linux-s390x@0.25.5: @@ -2248,7 +2214,6 @@ packages: engines: {node: '>=18'} cpu: [s390x] os: [linux] - requiresBuild: true dev: false optional: true @@ -2257,7 +2222,6 @@ packages: engines: {node: '>=18'} cpu: [s390x] os: [linux] - requiresBuild: true optional: true /@esbuild/linux-x64@0.25.5: @@ -2265,7 +2229,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [linux] - requiresBuild: true dev: false optional: true @@ -2274,7 +2237,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [linux] - requiresBuild: true optional: true /@esbuild/netbsd-arm64@0.25.5: @@ -2282,7 +2244,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [netbsd] - requiresBuild: true dev: false optional: true @@ -2291,7 +2252,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [netbsd] - requiresBuild: true optional: true /@esbuild/netbsd-x64@0.25.5: @@ -2299,7 +2259,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [netbsd] - requiresBuild: true dev: false optional: true @@ -2308,7 +2267,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [netbsd] - requiresBuild: true optional: true /@esbuild/openbsd-arm64@0.25.5: @@ -2316,7 +2274,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [openbsd] - requiresBuild: true dev: false optional: true @@ -2325,7 +2282,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [openbsd] - requiresBuild: true optional: true /@esbuild/openbsd-x64@0.25.5: @@ -2333,7 +2289,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [openbsd] - requiresBuild: true dev: false optional: true @@ -2342,7 +2297,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [openbsd] - requiresBuild: true optional: true /@esbuild/openharmony-arm64@0.25.8: @@ -2350,7 +2304,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [openharmony] - requiresBuild: true optional: true /@esbuild/sunos-x64@0.25.5: @@ -2358,7 +2311,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [sunos] - requiresBuild: true dev: false optional: true @@ -2367,7 +2319,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [sunos] - requiresBuild: true optional: true /@esbuild/win32-arm64@0.25.5: @@ -2375,7 +2326,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [win32] - requiresBuild: true dev: false optional: true @@ -2384,7 +2334,6 @@ packages: engines: {node: '>=18'} cpu: [arm64] os: [win32] - requiresBuild: true optional: true /@esbuild/win32-ia32@0.25.5: @@ -2392,7 +2341,6 @@ packages: engines: {node: '>=18'} cpu: [ia32] os: [win32] - requiresBuild: true dev: false optional: true @@ -2401,7 +2349,6 @@ packages: engines: {node: '>=18'} cpu: [ia32] os: [win32] - requiresBuild: true optional: true /@esbuild/win32-x64@0.25.5: @@ -2409,7 +2356,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [win32] - requiresBuild: true dev: false optional: true @@ -2418,7 +2364,6 @@ packages: engines: {node: '>=18'} cpu: [x64] os: [win32] - requiresBuild: true optional: true /@fastify/busboy@2.1.1: @@ -3292,7 +3237,6 @@ packages: /@firebase/util@1.12.1: resolution: {integrity: sha512-zGlBn/9Dnya5ta9bX/fgEoNC3Cp8s6h+uYPYaDieZsFOAdHP/ExzQ/eaDgxD3GOROdPkLKpvKY0iIzr9adle0w==} engines: {node: '>=18.0.0'} - requiresBuild: true dependencies: tslib: 2.8.1 dev: true @@ -3300,7 +3244,6 @@ packages: /@firebase/util@1.13.0: resolution: {integrity: sha512-0AZUyYUfpMNcztR5l09izHwXkZpghLgCUaAGjtMwXnCg3bj4ml5VgiwqOMOxJ+Nw4qN/zJAaOQBcJ7KGkWStqQ==} engines: {node: '>=20.0.0'} - requiresBuild: true dependencies: tslib: 2.8.1 @@ -4127,7 +4070,6 @@ packages: resolution: {integrity: sha512-LipbQobyEfQtu8WixasaFUZZ+JCGlho4OWwWIQ5ol0rB1RKkcZvypu7sS1CBvofBGVAa3vbOh8IOGQMrbmL5dg==} cpu: [arm64] os: [darwin] - requiresBuild: true dev: false optional: true @@ -4135,7 +4077,6 @@ packages: resolution: {integrity: sha512-yA+9P+ZeA3vg76BLXWeUomIAjxfmSmR2eg8fueHXDg5Xe1Xmkl9JCKuHXUhtJ+mMVcH12d5k4kJBLbyXTadfGQ==} cpu: [x64] os: [darwin] - requiresBuild: true dev: false optional: true @@ -4143,7 +4084,6 @@ packages: resolution: {integrity: sha512-OeWvSgjXXZ/zmtLqqL78I3910F6UYpUubmsUU+iBHo6nTtjkpXms95rJtGrjkWQqwswKBD7xSMplbYC4LEsiPA==} cpu: [arm64] os: [linux] - requiresBuild: true dev: false optional: true @@ -4151,7 +4091,6 @@ packages: resolution: {integrity: sha512-EDYrW9kle+8wI19JCj/PhRnGoCN9bked5cdOPdo1wdgH/HzjgoLPFTn9DHlZccgTEVhp3O+bpWXdN/rWySVvjw==} cpu: [arm] os: [linux] - requiresBuild: true dev: false optional: true @@ -4159,7 +4098,6 @@ packages: resolution: {integrity: sha512-wDd02mt5ScX4+xd6g78zKBr6ojpgCJCTrllCAabjgap5FzuETqOqaQfKhO+tJuGWv/J5q+GIds6uY7rNFueOxg==} cpu: [x64] os: [linux] - requiresBuild: true dev: false optional: true @@ -4167,7 +4105,6 @@ packages: resolution: {integrity: sha512-COotWhHJgzXULLiEjOgWQwqig6PoA+6ji6W+sDl6M1HhMXWIymEVHGs0edsVSNtsNSCAWMxJgR3asv6FNX/2EA==} cpu: [arm64] os: [win32] - requiresBuild: true dev: false optional: true @@ -4175,7 +4112,6 @@ packages: resolution: {integrity: sha512-kqUgQH+l8HDbkAapx+aoko7Ez4X4DqkIraOqY/k0QY5EN/iialVlFpBUXh4wFXzirdmEVjbIUMrceUh0Kh8LeA==} cpu: [x64] os: [win32] - requiresBuild: true dev: false optional: true @@ -4274,7 +4210,6 @@ packages: resolution: {integrity: sha512-QZHtlVgbAdy2zAqNA9Gu1UpIuI8Xvsd1v8ic6B2pZmeFnFcMWiPLfWXh7TVw4eGEZ/C9TH281KwhVoeQUKbyjw==} cpu: [arm64] os: [darwin] - requiresBuild: true dev: false optional: true @@ -4282,7 +4217,6 @@ packages: resolution: {integrity: sha512-mdzd3AVzYKuUmiWOQ8GNhl64/IoFGol569zNRdkLReh6LRLHOXxU4U8eq0JwaD8iFHdVGqSy4IjFL4reoWCDFw==} cpu: [x64] os: [darwin] - requiresBuild: true dev: false optional: true @@ -4290,7 +4224,6 @@ packages: resolution: {integrity: sha512-YxQL+ax0XqBJDZiKimS2XQaf+2wDGVa1enVRGzEvLLVFeqa5kx2bWbtcSXgsxjQB7nRqqIGFIcLteF/sHeVtQg==} cpu: [arm64] os: [linux] - requiresBuild: true dev: false optional: true @@ -4298,7 +4231,6 @@ packages: resolution: {integrity: sha512-fg0uy/dG/nZEXfYilKoRe7yALaNmHoYeIoJuJ7KJ+YyU2bvY8vPv27f7UKhGRpY6euFYqEVhxCFZgAUNQBM3nw==} cpu: [arm] os: [linux] - requiresBuild: true dev: false optional: true @@ -4306,7 +4238,6 @@ packages: resolution: {integrity: sha512-cvwNfbP07pKUfq1uH+S6KJ7dT9K8WOE4ZiAcsrSes+UY55E/0jLYc+vq+DO7jlmqRb5zAggExKm0H7O/CBaesg==} cpu: [x64] os: [linux] - requiresBuild: true dev: false optional: true @@ -4314,7 +4245,6 @@ packages: resolution: {integrity: sha512-x0fWaQtYp4E6sktbsdAqnehxDgEc/VwM7uLsRCYWaiGu0ykYdZPiS8zCWdnjHwyiumousxfBm4SO31eXqwEZhQ==} cpu: [x64] os: [win32] - requiresBuild: true dev: false optional: true @@ -4334,7 +4264,6 @@ packages: engines: {node: '>= 10'} cpu: [arm] os: [android] - requiresBuild: true dev: false optional: true @@ -4343,7 +4272,6 @@ packages: engines: {node: '>= 10'} cpu: [arm64] os: [android] - requiresBuild: true dev: false optional: true @@ -4352,7 +4280,6 @@ packages: engines: {node: '>= 10'} cpu: [arm64] os: [darwin] - requiresBuild: true dev: false optional: true @@ -4361,7 +4288,6 @@ packages: engines: {node: '>= 10'} cpu: [x64] os: [darwin] - requiresBuild: true dev: false optional: true @@ -4370,7 +4296,6 @@ packages: engines: {node: '>= 10'} cpu: [x64] os: [freebsd] - requiresBuild: true dev: false optional: true @@ -4379,7 +4304,6 @@ packages: engines: {node: '>= 10'} cpu: [arm] os: [linux] - requiresBuild: true dev: false optional: true @@ -4388,7 +4312,6 @@ packages: engines: {node: '>= 10'} cpu: [arm64] os: [linux] - requiresBuild: true dev: false optional: true @@ -4397,7 +4320,6 @@ packages: engines: {node: '>= 10'} cpu: [arm64] os: [linux] - requiresBuild: true dev: false optional: true @@ -4406,7 +4328,6 @@ packages: engines: {node: '>= 10'} cpu: [ppc64] os: [linux] - requiresBuild: true dev: false optional: true @@ -4415,7 +4336,6 @@ packages: engines: {node: '>= 10'} cpu: [riscv64] os: [linux] - requiresBuild: true dev: false optional: true @@ -4424,7 +4344,6 @@ packages: engines: {node: '>= 10'} cpu: [s390x] os: [linux] - requiresBuild: true dev: false optional: true @@ -4433,7 +4352,6 @@ packages: engines: {node: '>= 10'} cpu: [x64] os: [linux] - requiresBuild: true dev: false optional: true @@ -4442,7 +4360,6 @@ packages: engines: {node: '>= 10'} cpu: [x64] os: [linux] - requiresBuild: true dev: false optional: true @@ -4451,7 +4368,6 @@ packages: engines: {node: '>= 10'} cpu: [arm64] os: [win32] - requiresBuild: true dev: false optional: true @@ -4460,7 +4376,6 @@ packages: engines: {node: '>= 10'} cpu: [ia32] os: [win32] - requiresBuild: true dev: false optional: true @@ -4469,14 +4384,12 @@ packages: engines: {node: '>= 10'} cpu: [x64] os: [win32] - requiresBuild: true dev: false optional: true /@napi-rs/nice@1.0.4: resolution: {integrity: sha512-Sqih1YARrmMoHlXGgI9JrrgkzxcaaEso0AH+Y7j8NHonUs+xe4iDsgC3IBIDNdzEewbNpccNN6hip+b5vmyRLw==} engines: {node: '>= 10'} - requiresBuild: true optionalDependencies: '@napi-rs/nice-android-arm-eabi': 1.0.4 '@napi-rs/nice-android-arm64': 1.0.4 @@ -4943,7 +4856,6 @@ packages: engines: {node: '>= 10.0.0'} cpu: [arm64] os: [android] - requiresBuild: true dev: false optional: true @@ -4952,7 +4864,6 @@ packages: engines: {node: '>= 10.0.0'} cpu: [arm64] os: [darwin] - requiresBuild: true dev: false optional: true @@ -4961,7 +4872,6 @@ packages: engines: {node: '>= 10.0.0'} cpu: [x64] os: [darwin] - requiresBuild: true dev: false optional: true @@ -4970,7 +4880,6 @@ packages: engines: {node: '>= 10.0.0'} cpu: [x64] os: [freebsd] - requiresBuild: true dev: false optional: true @@ -4979,7 +4888,6 @@ packages: engines: {node: '>= 10.0.0'} cpu: [arm] os: [linux] - requiresBuild: true dev: false optional: true @@ -4988,7 +4896,6 @@ packages: engines: {node: '>= 10.0.0'} cpu: [arm] os: [linux] - requiresBuild: true dev: false optional: true @@ -4997,7 +4904,6 @@ packages: engines: {node: '>= 10.0.0'} cpu: [arm64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5006,7 +4912,6 @@ packages: engines: {node: '>= 10.0.0'} cpu: [arm64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5015,7 +4920,6 @@ packages: engines: {node: '>= 10.0.0'} cpu: [x64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5024,7 +4928,6 @@ packages: engines: {node: '>= 10.0.0'} cpu: [x64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5033,7 +4936,6 @@ packages: engines: {node: '>= 10.0.0'} cpu: [arm64] os: [win32] - requiresBuild: true dev: false optional: true @@ -5042,7 +4944,6 @@ packages: engines: {node: '>= 10.0.0'} cpu: [ia32] os: [win32] - requiresBuild: true dev: false optional: true @@ -5051,14 +4952,12 @@ packages: engines: {node: '>= 10.0.0'} cpu: [x64] os: [win32] - requiresBuild: true dev: false optional: true /@parcel/watcher@2.5.1: resolution: {integrity: sha512-dfUnCxiN9H4ap84DvD2ubjw+3vUNpstxa0TneY/Paat8a3R4uQZDLSvWjmznAY/DoahqTHl9V46HF/Zs3F29pg==} engines: {node: '>= 10.0.0'} - requiresBuild: true dependencies: detect-libc: 1.0.3 is-glob: 4.0.3 @@ -5084,7 +4983,6 @@ packages: /@pkgjs/parseargs@0.11.0: resolution: {integrity: sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==} engines: {node: '>=14'} - requiresBuild: true optional: true /@pnpm/config.env-replace@1.1.0: @@ -5223,7 +5121,6 @@ packages: resolution: {integrity: sha512-JkdNEq+DFxZfUwxvB58tHMHBHVgX23ew41g1OQinthJ+ryhdRk67O31S7sYw8u2lTjHUPFxwar07BBt1KHp/hg==} cpu: [arm] os: [android] - requiresBuild: true dev: false optional: true @@ -5231,7 +5128,6 @@ packages: resolution: {integrity: sha512-Zj3Hl6sN34xJtMv7Anwb5Gu01yujyE/cLBDB2gnHTAHaWS1Z38L7kuSG+oAh0giZMqG060f/YBStXtMH6FvPMA==} cpu: [arm] os: [android] - requiresBuild: true dev: false optional: true @@ -5239,7 +5135,6 @@ packages: resolution: {integrity: sha512-13unNoZ8NzUmnndhPTkWPWbX3vtHodYmy+I9kuLxN+F+l+x3LdVF7UCu8TWVMt1POHLh6oDHhnOA04n8oJZhBw==} cpu: [arm64] os: [android] - requiresBuild: true dev: false optional: true @@ -5247,7 +5142,6 @@ packages: resolution: {integrity: sha512-nTeCWY83kN64oQ5MGz3CgtPx8NSOhC5lWtsjTs+8JAJNLcP3QbLCtDDgUKQc/Ro/frpMq4SHUaHN6AMltcEoLQ==} cpu: [arm64] os: [android] - requiresBuild: true dev: false optional: true @@ -5255,7 +5149,6 @@ packages: resolution: {integrity: sha512-Gzf1Hn2Aoe8VZzevHostPX23U7N5+4D36WJNHK88NZHCJr7aVMG4fadqkIf72eqVPGjGc0HJHNuUaUcxiR+N/w==} cpu: [arm64] os: [darwin] - requiresBuild: true dev: false optional: true @@ -5263,7 +5156,6 @@ packages: resolution: {integrity: sha512-HV7bW2Fb/F5KPdM/9bApunQh68YVDU8sO8BvcW9OngQVN3HHHkw99wFupuUJfGR9pYLLAjcAOA6iO+evsbBaPQ==} cpu: [arm64] os: [darwin] - requiresBuild: true dev: false optional: true @@ -5271,7 +5163,6 @@ packages: resolution: {integrity: sha512-47N4hxa01a4x6XnJoskMKTS8XZ0CZMd8YTbINbi+w03A2w4j1RTlnGHOz/P0+Bg1LaVL6ufZyNprSg+fW5nYQQ==} cpu: [x64] os: [darwin] - requiresBuild: true dev: false optional: true @@ -5279,7 +5170,6 @@ packages: resolution: {integrity: sha512-SSj8TlYV5nJixSsm/y3QXfhspSiLYP11zpfwp6G/YDXctf3Xkdnk4woJIF5VQe0of2OjzTt8EsxnJDCdHd2xMA==} cpu: [x64] os: [darwin] - requiresBuild: true dev: false optional: true @@ -5287,7 +5177,6 @@ packages: resolution: {integrity: sha512-8t6aL4MD+rXSHHZUR1z19+9OFJ2rl1wGKvckN47XFRVO+QL/dUSpKA2SLRo4vMg7ELA8pzGpC+W9OEd1Z/ZqoQ==} cpu: [arm64] os: [freebsd] - requiresBuild: true dev: false optional: true @@ -5295,7 +5184,6 @@ packages: resolution: {integrity: sha512-ZyrsG4TIT9xnOlLsSSi9w/X29tCbK1yegE49RYm3tu3wF1L/B6LVMqnEWyDB26d9Ecx9zrmXCiPmIabVuLmNSg==} cpu: [arm64] os: [freebsd] - requiresBuild: true dev: false optional: true @@ -5303,7 +5191,6 @@ packages: resolution: {integrity: sha512-C+AyHBzfpsOEYRFjztcYUFsH4S7UsE9cDtHCtma5BK8+ydOZYgMmWg1d/4KBytQspJCld8ZIujFMAdKG1xyr4Q==} cpu: [x64] os: [freebsd] - requiresBuild: true dev: false optional: true @@ -5311,7 +5198,6 @@ packages: resolution: {integrity: sha512-pCgHFoOECwVCJ5GFq8+gR8SBKnMO+xe5UEqbemxBpCKYQddRQMgomv1104RnLSg7nNvgKy05sLsY51+OVRyiVw==} cpu: [x64] os: [freebsd] - requiresBuild: true dev: false optional: true @@ -5319,7 +5205,6 @@ packages: resolution: {integrity: sha512-de6TFZYIvJwRNjmW3+gaXiZ2DaWL5D5yGmSYzkdzjBDS3W+B9JQ48oZEsmMvemqjtAFzE16DIBLqd6IQQRuG9Q==} cpu: [arm] os: [linux] - requiresBuild: true dev: false optional: true @@ -5327,7 +5212,6 @@ packages: resolution: {integrity: sha512-EtP8aquZ0xQg0ETFcxUbU71MZlHaw9MChwrQzatiE8U/bvi5uv/oChExXC4mWhjiqK7azGJBqU0tt5H123SzVA==} cpu: [arm] os: [linux] - requiresBuild: true dev: false optional: true @@ -5335,7 +5219,6 @@ packages: resolution: {integrity: sha512-urjaEZubdIkacKc930hUDOfQPysezKla/O9qV+O89enqsqUmQm8Xj8O/vh0gHg4LYfv7Y7UsE3QjzLQzDYN1qg==} cpu: [arm] os: [linux] - requiresBuild: true dev: false optional: true @@ -5343,7 +5226,6 @@ packages: resolution: {integrity: sha512-qO7F7U3u1nfxYRPM8HqFtLd+raev2K137dsV08q/LRKRLEc7RsiDWihUnrINdsWQxPR9jqZ8DIIZ1zJJAm5PjQ==} cpu: [arm] os: [linux] - requiresBuild: true dev: false optional: true @@ -5351,7 +5233,6 @@ packages: resolution: {integrity: sha512-KlE8IC0HFOC33taNt1zR8qNlBYHj31qGT1UqWqtvR/+NuCVhfufAq9fxO8BMFC22Wu0rxOwGVWxtCMvZVLmhQg==} cpu: [arm64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5359,7 +5240,6 @@ packages: resolution: {integrity: sha512-3dRaqLfcOXYsfvw5xMrxAk9Lb1f395gkoBYzSFcc/scgRFptRXL9DOaDpMiehf9CO8ZDRJW2z45b6fpU5nwjng==} cpu: [arm64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5367,7 +5247,6 @@ packages: resolution: {integrity: sha512-j8CgxvfM0kbnhu4XgjnCWJQyyBOeBI1Zq91Z850aUddUmPeQvuAy6OiMdPS46gNFgy8gN1xkYyLgwLYZG3rBOg==} cpu: [arm64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5375,7 +5254,6 @@ packages: resolution: {integrity: sha512-fhHFTutA7SM+IrR6lIfiHskxmpmPTJUXpWIsBXpeEwNgZzZZSg/q4i6FU4J8qOGyJ0TR+wXBwx/L7Ho9z0+uDg==} cpu: [arm64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5383,7 +5261,6 @@ packages: resolution: {integrity: sha512-Ybc/1qUampKuRF4tQXc7G7QY9YRyeVSykfK36Y5Qc5dmrIxwFhrOzqaVTNoZygqZ1ZieSWTibfFhQ5qK8jpWxw==} cpu: [loong64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5391,7 +5268,6 @@ packages: resolution: {integrity: sha512-i7wfGFXu8x4+FRqPymzjD+Hyav8l95UIZ773j7J7zRYc3Xsxy2wIn4x+llpunexXe6laaO72iEjeeGyUFmjKeA==} cpu: [loong64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5399,7 +5275,6 @@ packages: resolution: {integrity: sha512-3FCIrnrt03CCsZqSYAOW/k9n625pjpuMzVfeI+ZBUSDT3MVIFDSPfSUgIl9FqUftxcUXInvFah79hE1c9abD+Q==} cpu: [ppc64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5407,7 +5282,6 @@ packages: resolution: {integrity: sha512-B/l0dFcHVUnqcGZWKcWBSV2PF01YUt0Rvlurci5P+neqY/yMKchGU8ullZvIv5e8Y1C6wOn+U03mrDylP5q9Yw==} cpu: [ppc64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5415,7 +5289,6 @@ packages: resolution: {integrity: sha512-QNU7BFHEvHMp2ESSY3SozIkBPaPBDTsfVNGx3Xhv+TdvWXFGOSH2NJvhD1zKAT6AyuuErJgbdvaJhYVhVqrWTg==} cpu: [riscv64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5423,7 +5296,6 @@ packages: resolution: {integrity: sha512-32k4ENb5ygtkMwPMucAb8MtV8olkPT03oiTxJbgkJa7lJ7dZMr0GCFJlyvy+K8iq7F/iuOr41ZdUHaOiqyR3iQ==} cpu: [riscv64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5431,7 +5303,6 @@ packages: resolution: {integrity: sha512-5W6vNYkhgfh7URiXTO1E9a0cy4fSgfE4+Hl5agb/U1sa0kjOLMLC1wObxwKxecE17j0URxuTrYZZME4/VH57Hg==} cpu: [riscv64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5439,7 +5310,6 @@ packages: resolution: {integrity: sha512-t5B2loThlFEauloaQkZg9gxV05BYeITLvLkWOkRXogP4qHXLkWSbSHKM9S6H1schf/0YGP/qNKtiISlxvfmmZw==} cpu: [riscv64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5447,7 +5317,6 @@ packages: resolution: {integrity: sha512-B7LKIz+0+p348JoAL4X/YxGx9zOx3sR+o6Hj15Y3aaApNfAshK8+mWZEf759DXfRLeL2vg5LYJBB7DdcleYCoQ==} cpu: [s390x] os: [linux] - requiresBuild: true dev: false optional: true @@ -5455,7 +5324,6 @@ packages: resolution: {integrity: sha512-YKjekwTEKgbB7n17gmODSmJVUIvj8CX7q5442/CK80L8nqOUbMtf8b01QkG3jOqyr1rotrAnW6B/qiHwfcuWQA==} cpu: [s390x] os: [linux] - requiresBuild: true dev: false optional: true @@ -5463,7 +5331,6 @@ packages: resolution: {integrity: sha512-lG7Xa+BmBNwpjmVUbmyKxdQJ3Q6whHjMjzQplOs5Z+Gj7mxPtWakGHqzMqNER68G67kmCX9qX57aRsW5V0VOng==} cpu: [x64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5471,7 +5338,6 @@ packages: resolution: {integrity: sha512-Jj5a9RUoe5ra+MEyERkDKLwTXVu6s3aACP51nkfnK9wJTraCC8IMe3snOfALkrjTYd2G1ViE1hICj0fZ7ALBPA==} cpu: [x64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5479,7 +5345,6 @@ packages: resolution: {integrity: sha512-tD46wKHd+KJvsmije4bUskNuvWKFcTOIM9tZ/RrmIvcXnbi0YK/cKS9FzFtAm7Oxi2EhV5N2OpfFB348vSQRXA==} cpu: [x64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5487,7 +5352,6 @@ packages: resolution: {integrity: sha512-7kX69DIrBeD7yNp4A5b81izs8BqoZkCIaxQaOpumcJ1S/kmqNFjPhDu1LHeVXv0SexfHQv5cqHsxLOjETuqDuA==} cpu: [x64] os: [linux] - requiresBuild: true dev: false optional: true @@ -5495,7 +5359,6 @@ packages: resolution: {integrity: sha512-Bjv/HG8RRWLNkXwQQemdsWw4Mg+IJ29LK+bJPW2SCzPKOUaMmPEppQlu/Fqk1d7+DX3V7JbFdbkh/NMmurT6Pg==} cpu: [arm64] os: [win32] - requiresBuild: true dev: false optional: true @@ -5503,7 +5366,6 @@ packages: resolution: {integrity: sha512-wiJWMIpeaak/jsbaq2HMh/rzZxHVW1rU6coyeNNpMwk5isiPjSTx0a4YLSlYDwBH/WBvLz+EtsNqQScZTLJy3g==} cpu: [arm64] os: [win32] - requiresBuild: true dev: false optional: true @@ -5511,7 +5373,6 @@ packages: resolution: {integrity: sha512-dt1llVSGEsGKvzeIO76HToiYPNPYPkmjhMHhP00T9S4rDern8P2ZWvWAQUEJ+R1UdMWJ/42i/QqJ2WV765GZcA==} cpu: [ia32] os: [win32] - requiresBuild: true dev: false optional: true @@ -5519,7 +5380,6 @@ packages: resolution: {integrity: sha512-gBgaUDESVzMgWZhcyjfs9QFK16D8K6QZpwAaVNJxYDLHWayOta4ZMjGm/vsAEy3hvlS2GosVFlBlP9/Wb85DqQ==} cpu: [ia32] os: [win32] - requiresBuild: true dev: false optional: true @@ -5527,7 +5387,6 @@ packages: resolution: {integrity: sha512-bwspbWB04XJpeElvsp+DCylKfF4trJDa2Y9Go8O6A7YLX2LIKGcNK/CYImJN6ZP4DcuOHB4Utl3iCbnR62DudA==} cpu: [x64] os: [win32] - requiresBuild: true dev: false optional: true @@ -5535,7 +5394,6 @@ packages: resolution: {integrity: sha512-CvUo2ixeIQGtF6WvuB87XWqPQkoFAFqW+HUo/WzHwuHDvIwZCtjdWXoYCcr06iKGydiqTclC4jU/TNObC/xKZg==} cpu: [x64] os: [win32] - requiresBuild: true dev: false optional: true @@ -6012,7 +5870,7 @@ packages: resolution: {integrity: sha512-FGJ6udDNUCjd19pp0Q3iTiDkwhYup7J8hpMW9c4k53NrccQFFWKRho6hvtPPEhnXWKvukfwAlB6DbDz4yhH5Gg==} dependencies: '@types/caseless': 0.12.5 - '@types/node': 24.1.0 + '@types/node': 24.2.0 '@types/tough-cookie': 4.0.5 form-data: 2.5.5 @@ -6465,7 +6323,6 @@ packages: /bare-events@2.6.0: resolution: {integrity: sha512-EKZ5BTXYExaNqi3I3f9RtEsaI/xBSGjE0XZCZilPzFAV/goswFHuPd9jEZlPIZ/iNZJwDSao9qRiScySz7MbQg==} - requiresBuild: true dev: true optional: true @@ -6736,7 +6593,6 @@ packages: /bufferutil@4.0.9: resolution: {integrity: sha512-WDtdLmJvAuNNPzByAYpRo2rF1Mmradw6gvWsQKf63476DDXmomT9zUiGypLcG4ibIM67vhAj8jJRdbmEws2Aqw==} engines: {node: '>=6.14.2'} - requiresBuild: true dependencies: node-gyp-build: 4.8.4 @@ -7538,14 +7394,12 @@ packages: resolution: {integrity: sha512-pGjwhsmsp4kL2RTz08wcOlGN83otlqHeD/Z5T8GXZB+/YcpQ/dgo+lbU8ZsGxV0HIvqqxo9l7mqYwyYMD9bKDg==} engines: {node: '>=0.10'} hasBin: true - requiresBuild: true dev: false optional: true /detect-libc@2.0.4: resolution: {integrity: sha512-3UDv+G9CsCKO1WKMGw9fwq/SWJYbI0c5Y7LU1AXYoDdbhE2AHQ6N6Nb34sG8Fj7T5APy8qXDCKuuIHd1BR0tVA==} engines: {node: '>=8'} - requiresBuild: true dev: false optional: true @@ -7827,7 +7681,6 @@ packages: resolution: {integrity: sha512-P8OtKZRv/5J5hhz0cUAdu/cLuPIKXpQl1R9pZtvmHWQvrAUVd0UNIPT4IB4W3rNOqVO0rlqHmCIbSwxh/c9yUQ==} engines: {node: '>=18'} hasBin: true - requiresBuild: true optionalDependencies: '@esbuild/aix-ppc64': 0.25.5 '@esbuild/android-arm': 0.25.5 @@ -7860,7 +7713,6 @@ packages: resolution: {integrity: sha512-vVC0USHGtMi8+R4Kz8rt6JhEWLxsv9Rnu/lGYbPR8u47B+DCBksq9JarW0zOO7bs37hyOK1l2/oqtbciutL5+Q==} engines: {node: '>=18'} hasBin: true - requiresBuild: true optionalDependencies: '@esbuild/aix-ppc64': 0.25.8 '@esbuild/android-arm': 0.25.8 @@ -8648,7 +8500,6 @@ packages: resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==} engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} os: [darwin] - requiresBuild: true optional: true /function-bind@1.1.2: @@ -9351,7 +9202,6 @@ packages: /install-artifact-from-github@1.4.0: resolution: {integrity: sha512-+y6WywKZREw5rq7U2jvr2nmZpT7cbWbQQ0N/qfcseYnzHFz2cZz1Et52oY+XttYuYeTkI8Y+R2JNWj68MpQFSg==} hasBin: true - requiresBuild: true dev: true optional: true @@ -10160,7 +10010,6 @@ packages: /lmdb@3.3.0: resolution: {integrity: sha512-MgJocUI6QEiSXQBFWLeyo1R7eQj8Rke5dlPxX0KFwli8/bsCxpM/KbXO5y0qmV/5llQ3wpneDWcTYxa+4vn8iQ==} hasBin: true - requiresBuild: true dependencies: msgpackr: 1.11.5 node-addon-api: 6.1.0 @@ -10676,7 +10525,6 @@ packages: /msgpackr-extract@3.0.3: resolution: {integrity: sha512-P0efT1C9jIdVRefqjzOQ9Xml57zpOXnIuS+csaB4MdZbTdmGDLo8XhzBG1N7aO11gKDDkJvBLULeFTo46wwreA==} hasBin: true - requiresBuild: true dependencies: node-gyp-build-optional-packages: 5.2.2 optionalDependencies: @@ -10691,7 +10539,6 @@ packages: /msgpackr@1.11.5: resolution: {integrity: sha512-UjkUHN0yqp9RWKy0Lplhh+wlpdt9oQBYgULZOiFhV3VclSF1JnSQWZ5r9gORQlNYaUKQoR8itv7g7z1xDDuACA==} - requiresBuild: true optionalDependencies: msgpackr-extract: 3.0.3 dev: false @@ -10724,7 +10571,6 @@ packages: /nan@2.23.0: resolution: {integrity: sha512-1UxuyYGdoQHcGg87Lkqm3FzefucTa0NAiOcuRsDmysep3c1LVCRK2krrUDafMWtjSG04htvAmvg96+SDknOmgQ==} - requiresBuild: true dev: true optional: true @@ -10782,13 +10628,11 @@ packages: /node-addon-api@6.1.0: resolution: {integrity: sha512-+eawOlIgy680F0kBzPUNFhMZGtJ1YmqM6l4+Crf4IkImjYrO/mqPwRMh352g23uIaQKFItcQ64I7KMaJxHgAVA==} - requiresBuild: true dev: false optional: true /node-addon-api@7.1.1: resolution: {integrity: sha512-5m3bsyrjFWE1xf7nz7YXdN4udnVtXK6/Yfgn5qnahL6bCkf2yKt4k3nuTKAtT4r3IG8JNR2ncsIMdZuAzJjHQQ==} - requiresBuild: true dev: false optional: true @@ -10835,7 +10679,6 @@ packages: /node-gyp-build-optional-packages@5.2.2: resolution: {integrity: sha512-s+w+rBWnpTMwSFbaE0UXsRlg7hU4FjekKU4eyAih5T8nJuNZT1nNsskXpxmeqSK9UzkBl6UgRlnKc8hz8IEqOw==} hasBin: true - requiresBuild: true dependencies: detect-libc: 2.0.4 dev: false @@ -11064,7 +10907,6 @@ packages: /ordered-binary@1.6.0: resolution: {integrity: sha512-IQh2aMfMIDbPjI/8a3Edr+PiOpcsB7yo8NdW7aHWVaoR/pcDldunMvnnwbk/auPGqmKeAdxtZl7MHX/QmPwhvQ==} - requiresBuild: true dev: false optional: true @@ -11303,7 +11145,6 @@ packages: /pg-cloudflare@1.2.7: resolution: {integrity: sha512-YgCtzMH0ptvZJslLM1ffsY4EuGaU0cx4XSdXLRFae8bPP4dS5xL1tNB3k2o/N64cHJpwU7dxKli/nZ2lUa5fLg==} - requiresBuild: true dev: true optional: true @@ -11548,7 +11389,6 @@ packages: /protobufjs@6.8.8: resolution: {integrity: sha512-AAmHtD5pXgZfi7GMpllpO3q1Xw1OYldr+dMUlAnffGTAhqkg72WdmSY71uKBF/JuyiKs8psYbtKrhi0ASCD8qw==} hasBin: true - requiresBuild: true dependencies: '@protobufjs/aspromise': 1.1.2 '@protobufjs/base64': 1.1.2 @@ -11567,7 +11407,6 @@ packages: /protobufjs@7.5.3: resolution: {integrity: sha512-sildjKwVqOI2kmFDiXQ6aEB0fjYTafpEvIBs8tOR8qI4spuL9OPROLVu2qZqi/xgCfsHIwVqlaF8JBjWFHnKbw==} engines: {node: '>=12.0.0'} - requiresBuild: true dependencies: '@protobufjs/aspromise': 1.1.2 '@protobufjs/base64': 1.1.2 @@ -11757,7 +11596,6 @@ packages: /re2@1.22.1(supports-color@10.1.0): resolution: {integrity: sha512-E4J0EtgyNLdIr0wTg0dQPefuiqNY29KaLacytiUAYYRzxCG+zOkWoUygt1rI+TA1LrhN49/njrfSO1DHtVC5Vw==} - requiresBuild: true dependencies: install-artifact-from-github: 1.4.0 nan: 2.23.0 @@ -13444,7 +13282,6 @@ packages: /utf-8-validate@6.0.5: resolution: {integrity: sha512-EYZR+OpIXp9Y1eG1iueg8KRsY8TuT8VNgnanZ0uA3STqhHQTLwbl+WX76/9X5OY12yQubymBpaBSmMPkSTQcKA==} engines: {node: '>=6.14.2'} - requiresBuild: true dependencies: node-gyp-build: 4.8.4 @@ -13611,7 +13448,6 @@ packages: /weak-lru-cache@1.2.2: resolution: {integrity: sha512-DEAoo25RfSYMuTGc9vPJzZcZullwIqRDSI9LOy+fkCJPi6hykCnfKaXTuPBDuXAUcqHXyOgFtHNp/kB2FjYHbw==} - requiresBuild: true dev: false optional: true diff --git a/shared-scripts/BUILD.bazel b/shared-scripts/BUILD.bazel deleted file mode 100644 index de00ed467..000000000 --- a/shared-scripts/BUILD.bazel +++ /dev/null @@ -1,8 +0,0 @@ -package(default_visibility = ["//visibility:public"]) - -filegroup( - name = "static_files", - srcs = glob(["*"]) + [ - "//shared-scripts/angular-optimization:static_files", - ], -) diff --git a/shared-scripts/README.md b/shared-scripts/README.md deleted file mode 100644 index abc0b25db..000000000 --- a/shared-scripts/README.md +++ /dev/null @@ -1,10 +0,0 @@ -## shared-scripts - -This is a Directory containing scripts that are commonly used in consumer Angular projects or -Bazel actions. - -#### Important Note for authors: - -We also expose the `BUILD.bazel` files here as this allows for fine-grained dependencies when -scripts are used within Bazel actions, and it helps with using these shared scripts directly -in the `angular/dev-infra` repository itself. diff --git a/shared-scripts/angular-optimization/BUILD.bazel b/shared-scripts/angular-optimization/BUILD.bazel deleted file mode 100644 index 97a75f797..000000000 --- a/shared-scripts/angular-optimization/BUILD.bazel +++ /dev/null @@ -1,31 +0,0 @@ -load("@build_bazel_rules_nodejs//:index.bzl", "copy_to_bin", "js_library") - -package(default_visibility = ["//visibility:public"]) - -filegroup( - name = "static_files", - srcs = glob(["*"]), -) - -# Exposed `js_library` targets need to copy files to `bazel-out`. More details here: -# https://github.com/bazelbuild/rules_nodejs/pull/3083. -copy_to_bin( - name = "js_lib_files", - srcs = [ - "ensure-no-linker-decl.mjs", - "esbuild-plugin.d.ts", - "esbuild-plugin.mjs", - ], -) - -js_library( - name = "js_lib", - package_name = "@angular/build-tooling/shared-scripts/angular-optimization", - srcs = [":js_lib_files"], - deps = [ - "@npm//@angular/build", - "@npm//@angular/compiler-cli", - "@npm//@babel/core", - "@npm//@babel/plugin-transform-async-generator-functions", - ], -) diff --git a/shared-scripts/angular-optimization/ensure-no-linker-decl.mjs b/shared-scripts/angular-optimization/ensure-no-linker-decl.mjs deleted file mode 100644 index 55c4c4dbe..000000000 --- a/shared-scripts/angular-optimization/ensure-no-linker-decl.mjs +++ /dev/null @@ -1,36 +0,0 @@ -/** - * @license - * Copyright Google LLC - * - * Use of this source code is governed by an MIT-style license that can be - * found in the LICENSE file at https://angular.io/license - */ - -/** Naively checks whether this node path resolves to an Angular declare invocation. */ -function isNgDeclareCallExpression(nodePath) { - if (!nodePath.node.name.startsWith('ɵɵngDeclare')) { - return false; - } - - // Expect the `ngDeclare` identifier to be used as part of a property access that - // is invoked within a call expression. e.g. `i0.ɵɵngDeclare<>`. - return ( - nodePath.parentPath?.type === 'MemberExpression' && - nodePath.parentPath.parentPath?.type === 'CallExpression' - ); -} - -/** Asserts that the given AST does not contain any Angular partial declaration. */ -export async function assertNoPartialDeclaration(filePath, ast, traverseFn) { - // Naively check if there are any Angular declarations left that haven't been linked. - traverseFn(ast, { - Identifier: (astPath) => { - if (isNgDeclareCallExpression(astPath)) { - throw astPath.buildCodeFrameError( - `Found Angular declaration that has not been linked. ${filePath}`, - Error, - ); - } - }, - }); -} diff --git a/shared-scripts/angular-optimization/esbuild-plugin.d.ts b/shared-scripts/angular-optimization/esbuild-plugin.d.ts deleted file mode 100644 index f6be3bbd0..000000000 --- a/shared-scripts/angular-optimization/esbuild-plugin.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * @license - * Copyright Google LLC - * - * Use of this source code is governed by an MIT-style license that can be - * found in the LICENSE file at https://angular.io/license - */ - -export interface OptimizationOptions { - enableLinker?: { - ensureNoPartialDeclaration: boolean; - filterPaths?: RegExp; - linkerOptions?: object; - }; - optimize?: { - isSideEffectFree?: (absoluteDiskPath: string) => boolean; - }; - downlevelAsyncGeneratorsIfPresent?: boolean; -} diff --git a/shared-scripts/angular-optimization/esbuild-plugin.mjs b/shared-scripts/angular-optimization/esbuild-plugin.mjs deleted file mode 100644 index 6825ba752..000000000 --- a/shared-scripts/angular-optimization/esbuild-plugin.mjs +++ /dev/null @@ -1,119 +0,0 @@ -/** - * @license - * Copyright Google LLC - * - * Use of this source code is governed by an MIT-style license that can be - * found in the LICENSE file at https://angular.io/license - */ - -import fs from 'fs'; -import babel from '@babel/core'; - -import {assertNoPartialDeclaration} from './ensure-no-linker-decl.mjs'; - -/** - * Creates an ESBuild plugin that configures various Angular optimization Babel plugins. - * The Babel plugins configured usually run in the Angular CLI compilation pipeline. - * - * @param {import('./esbuild-plugin').OptimizationOptions} opts Options - * @param additionalBabelPlugins List of additional Babel plugins that should run as part - * of this ESBuild plugin. This is primarily supported for reducing the amount of ESBuild - * load plugins needed (as they can impact performance significantly). - */ -export async function createEsbuildAngularOptimizePlugin(opts, additionalBabelPlugins = []) { - let linkerCreator = { - compiler: null, - babel: null, - }; - let downlevelAsyncGeneratorPlugin = null; - - if (opts.enableLinker) { - linkerCreator = { - compiler: await import('@angular/compiler-cli'), - babel: await import('@angular/compiler-cli/linker/babel'), - }; - } - - if (opts.downlevelAsyncGeneratorsIfPresent) { - downlevelAsyncGeneratorPlugin = ( - await import('@babel/plugin-transform-async-generator-functions') - ).default.default; - } - - const {adjustStaticMembers, adjustTypeScriptEnums, elideAngularMetadata, markTopLevelPure} = ( - await import('@angular/build/private') - ).default; - - return { - name: 'ng-babel-optimize-esbuild', - setup: (build) => { - build.onLoad({filter: /\.[cm]?js$/}, async (args) => { - const filePath = args.path; - const content = await fs.promises.readFile(filePath, 'utf8'); - const plugins = [...additionalBabelPlugins]; - - if (opts.optimize) { - plugins.push(adjustStaticMembers, adjustTypeScriptEnums, elideAngularMetadata); - - // If the current file is denoted as explicit side effect free, add the pure - // top-level functions optimization plugin for this file. - if (opts.optimize.isSideEffectFree && opts.optimize.isSideEffectFree(args.path)) { - plugins.push(markTopLevelPure); - } - } - - const shouldRunLinker = - opts.enableLinker && - (opts.enableLinker.filterPaths == null || opts.enableLinker.filterPaths.test(args.path)); - - if (shouldRunLinker) { - plugins.push( - linkerCreator.babel.createEs2015LinkerPlugin({ - ...(opts.enableLinker.linkerOptions ?? {}), - fileSystem: new linkerCreator.compiler.NodeJSFileSystem(), - logger: new linkerCreator.compiler.ConsoleLogger( - linkerCreator.compiler.LogLevel.warn, - ), - // Workaround for https://github.com/angular/angular/issues/42769 and https://github.com/angular/angular-cli/issues/22647. - sourceMapping: false, - }), - ); - } - - // Matches Angular CLIs detection: - // https://github.com/angular/angular-cli/blob/afe9feaa45913cbebe7f22c678d693d96f38584a/packages/angular_devkit/build_angular/src/builders/browser-esbuild/javascript-transformer.ts#L74-L76 - if ( - opts.downlevelAsyncGeneratorsIfPresent && - content.includes('async') && - /async(\s+function)?\s*\*/.test(content) - ) { - plugins.push(downlevelAsyncGeneratorPlugin); - } - - // If no plugins are enabled, return the original code and save time. - if (plugins.length === 0) { - return {contents: content}; - } - - const ensureNoPartialDeclaration = - opts.enableLinker && opts.enableLinker.ensureNoPartialDeclaration; - const {code, ast} = await babel.transformAsync(content, { - filename: filePath, - filenameRelative: filePath, - plugins: plugins, - // Sourcemaps are generated inline so that ESBuild can process them. - sourceMaps: 'inline', - compact: false, - // AST is needed when we want to ensure no partial declarations later. - ast: ensureNoPartialDeclaration, - }); - - if (ensureNoPartialDeclaration) { - assertNoPartialDeclaration(filePath, ast, babel.traverse); - } - - return {contents: code}; - }); - }, - }; -} diff --git a/shared-scripts/tsconfig.json b/shared-scripts/tsconfig.json deleted file mode 100644 index c1a1c7102..000000000 --- a/shared-scripts/tsconfig.json +++ /dev/null @@ -1,4 +0,0 @@ -// IDE config. Compile options should be changed in the top-level project config. -{ - "extends": "../tsconfig.json" -} diff --git a/tools/defaults.bzl b/tools/defaults.bzl deleted file mode 100644 index e01f02e73..000000000 --- a/tools/defaults.bzl +++ /dev/null @@ -1,92 +0,0 @@ -load("@build_bazel_rules_nodejs//:index.bzl", _pkg_npm = "pkg_npm") -load("@npm//@angular/bazel:index.bzl", _ng_module = "ng_module") -load("@npm//@bazel/concatjs:index.bzl", _ts_library = "ts_library") -load("//:package.bzl", "BZL_DEFAULTS_ALLOW_PACKAGES") -load( - "//tools:esbuild.bzl", - _esbuild = "esbuild", - _esbuild_checked_in = "esbuild_checked_in", - _esbuild_cjs_bundle = "esbuild_cjs_bundle", - _esbuild_config = "esbuild_config", - _esbuild_esm_bundle = "esbuild_esm_bundle", -) -load("//tools/jasmine:jasmine.bzl", _jasmine_node_test = "jasmine_node_test") - -esbuild = _esbuild -esbuild_config = _esbuild_config -esbuild_esm_bundle = _esbuild_esm_bundle -esbuild_checked_in = _esbuild_checked_in -esbuild_cjs_bundle = _esbuild_cjs_bundle - -jasmine_node_test = _jasmine_node_test - -def _assert_defaults_allowed_for_caller(): - current_pkg = native.package_name() - - for allow_package in BZL_DEFAULTS_ALLOW_PACKAGES: - if current_pkg.startswith("%s/" % allow_package) or \ - current_pkg == allow_package: - return - - # For `test/` or `tests/` packages in forbidden Bazel packages, we allow usage - # of defaults. This check is not fully reliable but sufficient to avoid easy mistakes. - if "test/" in current_pkg or current_pkg.endswith("test") or \ - "tests/" in current_pkg or current_pkg.endswith("tests"): - return - - fail("Cannot use `defaults.bzl` from within %s" % current_pkg) - -def _get_module_name(testonly, user_module_name): - if testonly: - return None - - current_pkg = native.package_name() - - if current_pkg.startswith("ng-dev") and user_module_name == None: - # We only auto-generate the `module_name` for targets in `ng-dev`. Other targets should - # have an explicit `module_name` as we cannot rely on this macro in consumer workspaces. - return "@angular/ng-dev/%s" % current_pkg - - if current_pkg.startswith("docs") and user_module_name == None: - # We only auto-generate the `module_name` for targets in `ng-dev`. Other targets should - # have an explicit `module_name` as we cannot rely on this macro in consumer workspaces. - return "@angular/%s" % current_pkg - - return None - -def ts_library(name, testonly = False, deps = [], srcs = [], devmode_module = None, module_name = None, **kwargs): - _assert_defaults_allowed_for_caller() - deps = deps + ["@npm//tslib"] - - _ts_library( - name = name, - devmode_module = devmode_module if devmode_module != None else "esnext", - devmode_target = "es2020", - prodmode_module = "esnext", - prodmode_target = "es2020", - tsconfig = kwargs.pop("tsconfig", "//:tsconfig"), - testonly = testonly, - deps = deps, - srcs = srcs, - module_name = kwargs.pop("module_name", _get_module_name(testonly, module_name)), - package_name = kwargs.pop("package_name", _get_module_name(testonly, module_name)), - **kwargs - ) - -def pkg_npm(deps = [], **kwargs): - _assert_defaults_allowed_for_caller() - - _pkg_npm( - deps = deps, - **kwargs - ) - -def ng_module(name, testonly = False, module_name = None, **kwargs): - _assert_defaults_allowed_for_caller() - - _ng_module( - name = name, - module_name = kwargs.pop("module_name", _get_module_name(testonly, module_name)), - tsconfig = kwargs.pop("tsconfig", "//:tsconfig"), - **kwargs - ) diff --git a/tools/defaults2.bzl b/tools/defaults2.bzl index a588ea88f..9641cf26b 100644 --- a/tools/defaults2.bzl +++ b/tools/defaults2.bzl @@ -7,24 +7,31 @@ load("@aspect_rules_js//npm:defs.bzl", _npm_package = "npm_package") load("@aspect_rules_ts//ts:defs.bzl", _ts_config = "ts_config") load("@rules_angular//src/ng_package/text_replace:index.bzl", _text_replace = "text_replace") load("@rules_angular//src/ng_project:index.bzl", _ng_project = "ng_project") +load("@rules_angular//src/ts_project:index.bzl", _ts_project = "ts_project") +load("@rules_sass//src:index.bzl", _npm_sass_library = "npm_sass_library", _sass_binary = "sass_binary") load("//bazel:extract_types.bzl", _extract_types = "extract_types") -load("//tools:ts_project_interop.bzl", _ts_project = "ts_project") copy_to_bin = _copy_to_bin ts_config = _ts_config js_binary = _js_binary esbuild = _esbuild extract_types = _extract_types +npm_sass_library = _npm_sass_library +sass_binary = _sass_binary def _determine_tsconfig(testonly): if native.package_name().startswith("ng-dev"): return "//ng-dev:tsconfig_test" if testonly else "//ng-dev:tsconfig" + if native.package_name().startswith("apps"): + return "//apps:tsconfig" + def ts_project( name, source_map = True, testonly = False, tsconfig = None, + declaration = True, **kwargs): if tsconfig == None: tsconfig = _determine_tsconfig(testonly) @@ -34,6 +41,7 @@ def ts_project( source_map = source_map, testonly = testonly, tsconfig = tsconfig, + declaration = declaration, **kwargs ) @@ -42,16 +50,20 @@ def ng_project( source_map = True, testonly = False, tsconfig = None, + declaration = True, + deps = [], **kwargs): if tsconfig == None: tsconfig = _determine_tsconfig(testonly) - _ts_project( + deps = deps + ["//:node_modules/tslib"] + _ng_project( name, source_map = source_map, - rule_impl = _ng_project, + declaration = declaration, testonly = testonly, tsconfig = tsconfig, + deps = deps, **kwargs ) diff --git a/tools/esbuild.bzl b/tools/esbuild.bzl deleted file mode 100644 index e1d7d6e64..000000000 --- a/tools/esbuild.bzl +++ /dev/null @@ -1,94 +0,0 @@ -load("@build_bazel_rules_nodejs//:index.bzl", "generated_file_test") -load("//tools/esbuild/old-esbuild:extract_js_module_output.bzl", "extract_js_module_output") -load( - "//tools/esbuild/old-esbuild:index.bzl", - _esbuild = "esbuild", - _esbuild_cjs_bundle = "esbuild_cjs_bundle", - _esbuild_config = "esbuild_config", - _esbuild_esm_bundle = "esbuild_esm_bundle", -) - -esbuild_config = _esbuild_config - -def _esbuild_devmode_prioritize( - esbuild_rule, - name, - testonly = False, - platform = "node", - target = "node20", - deps = [], - **kwargs): - # TODO: Rename once devmode and prodmode have been combined. - # This helps speeding up building as ESBuild (used internally by the rule) would - # request both devmode and prodmode output flavor (resulting in 2x TS compilations). - # Note: Devmode is equivalent to Prodmode and Prodmode breaks `.js` extensions. - extract_js_module_output( - name = "%s_devmode_deps" % name, - deps = deps, - testonly = testonly, - provider = "JSModuleInfo", - forward_linker_mappings = True, - include_external_npm_packages = True, - include_default_files = False, - include_declarations = False, - ) - - esbuild_rule( - name = name, - platform = platform, - target = target, - testonly = testonly, - deps = [":%s_devmode_deps" % name], - **kwargs - ) - -def esbuild(**kwargs): - _esbuild_devmode_prioritize( - _esbuild, - **kwargs - ) - -def esbuild_esm_bundle(**kwargs): - _esbuild_devmode_prioritize( - _esbuild_esm_bundle, - **kwargs - ) - -def esbuild_cjs_bundle(**kwargs): - _esbuild_devmode_prioritize( - _esbuild_cjs_bundle, - **kwargs - ) - -def esbuild_checked_in(name, **kwargs): - esbuild_esm_bundle( - name = "%s_generated" % name, - # Unfortunately we need to omit source maps from the checked-in files as these - # will vary based on the platform. See more details below in the sanitization - # genrule transformation. It is acceptable not having source-maps for the checked-in - # files as those are not minified and its to debug, the checked-in file can be visited. - sourcemap = "external", - # We always disable minification for checked-in files as otherwise it will - # become difficult determining potential differences. e.g. on Windows ESBuild - # accidentally included `source-map-support` due to the missing sandbox. - minify = False, - **kwargs - ) - - # ESBuild adds comments and function identifiers with the name of their module - # location. e.g. `"bazel-out/x64_windows-fastbuild/bin/node_modules/a"function(exports)`. - # We strip all of these paths as that would break approval of the he checked-in files within - # different platforms (e.g. RBE running with K8). Additionally these paths depend - # on the non-deterministic hoisting of the package manager across all platforms. - native.genrule( - name = "%s_sanitized" % name, - srcs = ["%s_generated.js" % name], - outs = ["%s_sanitized.js" % name], - cmd = """cat $< | sed -E "s#(bazel-out|node_modules)/[^\\"']+##g" > $@""", - ) - - generated_file_test( - name = name, - src = "%s.js" % name, - generated = "%s_sanitized.js" % name, - ) diff --git a/tools/esbuild/index.bzl b/tools/esbuild/index.bzl deleted file mode 100644 index e1d7d6e64..000000000 --- a/tools/esbuild/index.bzl +++ /dev/null @@ -1,94 +0,0 @@ -load("@build_bazel_rules_nodejs//:index.bzl", "generated_file_test") -load("//tools/esbuild/old-esbuild:extract_js_module_output.bzl", "extract_js_module_output") -load( - "//tools/esbuild/old-esbuild:index.bzl", - _esbuild = "esbuild", - _esbuild_cjs_bundle = "esbuild_cjs_bundle", - _esbuild_config = "esbuild_config", - _esbuild_esm_bundle = "esbuild_esm_bundle", -) - -esbuild_config = _esbuild_config - -def _esbuild_devmode_prioritize( - esbuild_rule, - name, - testonly = False, - platform = "node", - target = "node20", - deps = [], - **kwargs): - # TODO: Rename once devmode and prodmode have been combined. - # This helps speeding up building as ESBuild (used internally by the rule) would - # request both devmode and prodmode output flavor (resulting in 2x TS compilations). - # Note: Devmode is equivalent to Prodmode and Prodmode breaks `.js` extensions. - extract_js_module_output( - name = "%s_devmode_deps" % name, - deps = deps, - testonly = testonly, - provider = "JSModuleInfo", - forward_linker_mappings = True, - include_external_npm_packages = True, - include_default_files = False, - include_declarations = False, - ) - - esbuild_rule( - name = name, - platform = platform, - target = target, - testonly = testonly, - deps = [":%s_devmode_deps" % name], - **kwargs - ) - -def esbuild(**kwargs): - _esbuild_devmode_prioritize( - _esbuild, - **kwargs - ) - -def esbuild_esm_bundle(**kwargs): - _esbuild_devmode_prioritize( - _esbuild_esm_bundle, - **kwargs - ) - -def esbuild_cjs_bundle(**kwargs): - _esbuild_devmode_prioritize( - _esbuild_cjs_bundle, - **kwargs - ) - -def esbuild_checked_in(name, **kwargs): - esbuild_esm_bundle( - name = "%s_generated" % name, - # Unfortunately we need to omit source maps from the checked-in files as these - # will vary based on the platform. See more details below in the sanitization - # genrule transformation. It is acceptable not having source-maps for the checked-in - # files as those are not minified and its to debug, the checked-in file can be visited. - sourcemap = "external", - # We always disable minification for checked-in files as otherwise it will - # become difficult determining potential differences. e.g. on Windows ESBuild - # accidentally included `source-map-support` due to the missing sandbox. - minify = False, - **kwargs - ) - - # ESBuild adds comments and function identifiers with the name of their module - # location. e.g. `"bazel-out/x64_windows-fastbuild/bin/node_modules/a"function(exports)`. - # We strip all of these paths as that would break approval of the he checked-in files within - # different platforms (e.g. RBE running with K8). Additionally these paths depend - # on the non-deterministic hoisting of the package manager across all platforms. - native.genrule( - name = "%s_sanitized" % name, - srcs = ["%s_generated.js" % name], - outs = ["%s_sanitized.js" % name], - cmd = """cat $< | sed -E "s#(bazel-out|node_modules)/[^\\"']+##g" > $@""", - ) - - generated_file_test( - name = name, - src = "%s.js" % name, - generated = "%s_sanitized.js" % name, - ) diff --git a/tools/esbuild/old-esbuild/BUILD.bazel b/tools/esbuild/old-esbuild/BUILD.bazel deleted file mode 100644 index 37bc2e734..000000000 --- a/tools/esbuild/old-esbuild/BUILD.bazel +++ /dev/null @@ -1,9 +0,0 @@ -package(default_visibility = ["//visibility:public"]) - -exports_files(["esbuild-amd-config.mjs"]) - -# Make source files available for distribution via pkg_npm -filegroup( - name = "files", - srcs = glob(["*"]), -) diff --git a/tools/esbuild/old-esbuild/esbuild-amd-config.mjs b/tools/esbuild/old-esbuild/esbuild-amd-config.mjs deleted file mode 100644 index bb69033b9..000000000 --- a/tools/esbuild/old-esbuild/esbuild-amd-config.mjs +++ /dev/null @@ -1,25 +0,0 @@ -import url from 'url'; -import path from 'path'; - -/** Path to the ESBuild configuration maintained by the user. */ -const userConfigExecPath = 'TMPL_CONFIG_PATH'; - -/** User ESBuild config. Empty if none is loaded. */ -let userConfig = {}; - -if (userConfigExecPath !== '') { - const userConfigPath = path.join(process.cwd(), userConfigExecPath); - const userConfigUrl = url.pathToFileURL(userConfigPath); - - // Load the user config, assuming it is set as `default` export. This is - // usually an `export default` statement or a named export named `default`. - userConfig = (await import(userConfigUrl)).default; -} - -export default { - ...userConfig, - globalName: '__exports', - format: 'iife', - banner: {js: 'define("TMPL_MODULE_NAME", [], function() {'}, - footer: {js: 'return __exports;})'}, -}; diff --git a/tools/esbuild/old-esbuild/extract_js_module_output.bzl b/tools/esbuild/old-esbuild/extract_js_module_output.bzl deleted file mode 100644 index 30a9cebba..000000000 --- a/tools/esbuild/old-esbuild/extract_js_module_output.bzl +++ /dev/null @@ -1,122 +0,0 @@ -load("@build_bazel_rules_nodejs//:providers.bzl", "DeclarationInfo", "ExternalNpmPackageInfo", "JSEcmaScriptModuleInfo", "JSNamedModuleInfo", "node_modules_aspect") -load("@build_bazel_rules_nodejs//internal/linker:link_node_modules.bzl", "LinkerPackageMappingInfo", "module_mappings_aspect") -load("@rules_nodejs//nodejs:providers.bzl", "JSModuleInfo") - -"""Converts a provider name to its actually Starlark provider instance.""" - -def _name_to_js_module_provider(name): - if name == "JSModuleInfo": - return JSModuleInfo - elif name == "JSNamedModuleInfo": - return JSNamedModuleInfo - elif name == "JSEcmaScriptModuleInfo": - return JSEcmaScriptModuleInfo - fail("Unexpected JavaScript module provider.") - -"""Implementation of the extract_js_module_output rule.""" - -def _extract_js_module_output_impl(ctx): - js_module_provider = _name_to_js_module_provider(ctx.attr.provider) - transitive_mappings = [] - transitive_node_modules_roots = [] - depsets = [] - - for dep in ctx.attr.deps: - # Include JavaScript sources (including transitive outputs) based on the - # configured JavaScript module provider. - if js_module_provider in dep: - depsets.append(dep[js_module_provider].sources) - - # If external NPM package sources should be included, we also capture the - # sources (including transitive external NPM packages). - if ctx.attr.include_external_npm_packages and ExternalNpmPackageInfo in dep: - depsets.append(dep[ExternalNpmPackageInfo].sources) - - # If we intend to forward linker mappings, capture first-party package - # linker mappings and collect them in a dictionary that we will re-expose. - if ctx.attr.forward_linker_mappings and LinkerPackageMappingInfo in dep: - transitive_mappings.append(dep[LinkerPackageMappingInfo].mappings) - transitive_node_modules_roots.append(dep[LinkerPackageMappingInfo].node_modules_roots) - - # Based on whether declarations should be collected, extract direct - # and transitive declaration files using the `DeclarationInfo` provider. - if ctx.attr.include_declarations and DeclarationInfo in dep: - depsets.append(dep[DeclarationInfo].transitive_declarations) - - # Based on whether default files should be collected, extract direct - # files which are exposed using the `DefaultInfo` provider. Also include - # data runfiles which are needed for the current target. - # https://docs.bazel.build/versions/main/skylark/lib/DefaultInfo.html#data_runfiles - if ctx.attr.include_default_files and DefaultInfo in dep: - depsets.append(dep[DefaultInfo].files) - depsets.append(dep[DefaultInfo].data_runfiles.files) - - sources = depset(transitive = depsets) - - return [ - DefaultInfo(files = sources), - LinkerPackageMappingInfo( - # Example of how linker mappings are constructed in `rules_nodejs`. - # https://github.com/bazelbuild/rules_nodejs/blob/ae49c0e85a60234f273ea6629bc6056ab293fe5b/internal/linker/link_node_modules.bzl#L220-L222. - mappings = depset(transitive = transitive_mappings), - node_modules_roots = depset(transitive = transitive_node_modules_roots), - ), - ] - -""" - Rule that collects declared JavaScript module output files from a list of dependencies - based on a configurable JavaScript module provider. The extracted outputs are exposed - within the `DefaultInfo` provider. Targets defined using this rule can be used as input - for rules that require JavaScript sources, or if there are multiple JavaScript output - variants defined for a target while for example only the `JSModule` outputs are of interest. - - As an example: This rule is helpful in combination with `ts_library` and `ng_module` as - those rule expose multiple output flavors (which are distinguishable by the JavaScript module - providers as imported from `providers.bzl`). i.e. these rules expose flavors for named AMD - modules and ECMAScript module output. For reference: - https://github.com/bazelbuild/rules_nodejs/blob/stable/packages/typescript/internal/build_defs.bzl#L334-L337 -""" -extract_js_module_output = rule( - implementation = _extract_js_module_output_impl, - attrs = { - "deps": attr.label_list( - allow_files = True, - aspects = [module_mappings_aspect, node_modules_aspect], - ), - "provider": attr.string( - doc = "JavaScript module info provider that is used for collecting sources from the dependencies.", - mandatory = True, - values = ["JSModuleInfo", "JSNamedModuleInfo", "JSEcmaScriptModuleInfo"], - ), - "forward_linker_mappings": attr.bool( - mandatory = True, - doc = """ - Whether linker mappings of the dependencies should be forwarded. - - This can be useful when the sources are put into JavaScript consuming rules - where module mappings are relevant. e.g. when passed as `deps` to `esbuild`. - """, - ), - "include_external_npm_packages": attr.bool( - mandatory = True, - doc = """ - Whether external NPM package sources should be extracted as well. - - NPM packages can contain arbitrary sources that would be included. e.g. a - package could also contain `.json` files that would be extracted here. Also - note that there is no separation of the JS-based providers for external packages, - """, - ), - "include_declarations": attr.bool( - mandatory = True, - doc = "Whether declaration files should be collected from the dependencies.", - ), - "include_default_files": attr.bool( - mandatory = True, - doc = """ - Whether files from the `DefaultInfo` provider should be collected. Includes - data runfiles needed for the default outputs from dependencies. - """, - ), - }, -) diff --git a/tools/esbuild/old-esbuild/index.bzl b/tools/esbuild/old-esbuild/index.bzl deleted file mode 100644 index d87f0bb8c..000000000 --- a/tools/esbuild/old-esbuild/index.bzl +++ /dev/null @@ -1,104 +0,0 @@ -load("@npm//@bazel/esbuild:index.bzl", _esbuild = "esbuild", _esbuild_config = "esbuild_config") -load("//bazel:expand_template.bzl", "expand_template") - -# Re-export of the actual esbuild definitions. -esbuild_config = _esbuild_config - -def esbuild( - name, - # Inline source contents to make debugging easier. Contents are inlined by default - # in ESBuild but `@bazel/esbuild` sets the default to `false`. Inlining sources is - # helpful as otherwise developers would need to manually wire up the Bazel execroot - # as workspace in the Chrome devtools. - # https://github.com/bazelbuild/rules_nodejs/blob/c30a26c13d20dac48dc9f220370cb02a317b13f3/packages/esbuild/esbuild.bzl#L333. - sources_content = True, - # Never build a metadata file by default. It's not needed in most use-cases. - metafile = False, - **kwargs): - _esbuild( - name = name, - sources_content = sources_content, - metafile = metafile, - **kwargs - ) - -def esbuild_esm_bundle(name, define = {}, **kwargs): - """ESBuild macro supports an ESM/CJS interop. - - Args: - name: Name of the target - **kwargs: Other arguments passed to the `esbuild` rule. - """ - - args = dict( - resolveExtensions = [".mjs", ".js", ".json"], - outExtension = {".js": ".mjs"}, - # Workaround for: https://github.com/evanw/esbuild/issues/1921. - banner = { - "js": """ -import {createRequire as __cjsCompatRequire} from 'module'; -const require = __cjsCompatRequire(import.meta.url); -""", - }, - define = define, - ) - - esbuild( - name = name, - format = "esm", - args = args, - **kwargs - ) - -def esbuild_cjs_bundle(name, **kwargs): - """ESBuild macro supports an ESM/CJS interop. - - Args: - name: Name of the target - **kwargs: Other arguments passed to the `esbuild` rule. - """ - - args = dict( - resolveExtensions = [".cjs", ".js", ".json"], - outExtension = {".js": ".cjs"}, - ) - - esbuild( - name = name, - format = "cjs", - args = args, - **kwargs - ) - -def esbuild_amd(name, entry_point, module_name, testonly = False, config = None, deps = [], **kwargs): - """Generates an AMD bundle for the specified entry-point with the given AMD module name.""" - expand_template( - name = "%s_config" % name, - testonly = testonly, - template = "//tools/esbuild/old-esbuild:esbuild-amd-config.mjs", - output_name = "%s_config.mjs" % name, - substitutions = { - "TMPL_MODULE_NAME": module_name, - "TMPL_CONFIG_PATH": "$(execpath %s)" % config if config else "", - }, - data = [config] if config else None, - ) - - _esbuild_config( - name = "%s_config_lib" % name, - testonly = testonly, - config_file = "%s_config" % name, - # Adds the user configuration and its deps as dependency of the AMD ESBuild config. - # https://github.com/bazelbuild/rules_nodejs/blob/a892caf5a040bae5eeec174a3cf6250f02caf364/packages/esbuild/esbuild_config.bzl#L23. - deps = [config, "%s_deps" % config] if config else None, - ) - - esbuild( - name = name, - testonly = testonly, - deps = deps, - entry_point = entry_point, - format = "iife", - config = "%s_config_lib" % name, - **kwargs - ) diff --git a/tools/jasmine/BUILD.bazel b/tools/jasmine/BUILD.bazel deleted file mode 100644 index 36343ac79..000000000 --- a/tools/jasmine/BUILD.bazel +++ /dev/null @@ -1,15 +0,0 @@ -load("//tools:defaults.bzl", "ts_library") - -ts_library( - name = "bootstrap", - testonly = True, - srcs = [ - "bootstrap.init.ts", - ], - visibility = ["//visibility:public"], - deps = [ - "//ng-dev/utils:config_cache", - "//ng-dev/utils/testing:bazel-env", - "@npm//@types/jasmine", - ], -) diff --git a/tools/jasmine/bootstrap.init.ts b/tools/jasmine/bootstrap.init.ts deleted file mode 100644 index 1a1f1eefd..000000000 --- a/tools/jasmine/bootstrap.init.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * @license - * Copyright Google LLC - * - * Use of this source code is governed by an MIT-style license that can be - * found in the LICENSE file at https://angular.io/license - */ -import {setCachedConfig} from '../../ng-dev/utils/config-cache.js'; -import {cleanTestTmpDir} from '../../ng-dev/utils/testing/bazel-env.js'; - -beforeEach(() => { - // Before each spec runs, clean the temporary test dir to prevent specs from effecting each other. - cleanTestTmpDir(); - // Reset the cached ng-dev configuration between specs. - setCachedConfig({}); -}); diff --git a/tools/jasmine/jasmine.bzl b/tools/jasmine/jasmine.bzl deleted file mode 100644 index 780e39ec9..000000000 --- a/tools/jasmine/jasmine.bzl +++ /dev/null @@ -1,25 +0,0 @@ -load("@npm//@bazel/jasmine:index.bzl", _jasmine_node_test = "jasmine_node_test") -load("//tools/jasmine/old-spec-bundling:spec_bundle.bzl", "spec_bundle") - -def jasmine_node_test(name, specs = [], external = [], bootstrap = ["//tools/jasmine:bootstrap"], **kwargs): - templated_args = kwargs.pop("templated_args", []) + [ - # TODO: Disable the linker fully here. Currently it is needed for ESM. - "--bazel_patch_module_resolver", - ] - - spec_bundle( - name = "%s_test_bundle" % name, - platform = "node", - target = "es2022", - bootstrap = bootstrap, - deps = specs, - external = external, - ) - - _jasmine_node_test( - name = name, - srcs = [":%s_test_bundle" % name], - use_direct_specs = True, - templated_args = templated_args, - **kwargs - ) diff --git a/tools/jasmine/old-spec-bundling/BUILD.bazel b/tools/jasmine/old-spec-bundling/BUILD.bazel deleted file mode 100644 index b61875431..000000000 --- a/tools/jasmine/old-spec-bundling/BUILD.bazel +++ /dev/null @@ -1 +0,0 @@ -exports_files(["esbuild.config-tmpl.mjs"]) diff --git a/tools/jasmine/old-spec-bundling/esbuild.config-tmpl.mjs b/tools/jasmine/old-spec-bundling/esbuild.config-tmpl.mjs deleted file mode 100644 index d3f75652f..000000000 --- a/tools/jasmine/old-spec-bundling/esbuild.config-tmpl.mjs +++ /dev/null @@ -1,63 +0,0 @@ -/** - * @license - * Copyright Google LLC - * - * Use of this source code is governed by an MIT-style license that can be - * found in the LICENSE file at https://angular.io/license - */ - -const downlevelAsyncAwait = TMPL_DOWNLEVEL_ASYNC_AWAIT; -const enableLinker = TMPL_RUN_LINKER; - -// List of esbuild plugins. -const plugins = []; -if (enableLinker || downlevelAsyncAwait) { - const {createEsbuildAngularOptimizePlugin} = await import( - '@angular/build-tooling/shared-scripts/angular-optimization/esbuild-plugin.mjs' - ); - - plugins.push( - await createEsbuildAngularOptimizePlugin({ - optimize: undefined, - downlevelAsyncGeneratorsIfPresent: downlevelAsyncAwait, - enableLinker: enableLinker - ? { - ensureNoPartialDeclaration: true, - linkerOptions: { - // JIT mode is needed for tests overriding components/modules etc. - linkerJitMode: true, - unknownDeclarationVersionHandling: TMPL_LINKER_UNKNOWN_DECLARATION_HANDLING, - }, - } - : undefined, - }), - ); -} - -// List of supported features as per ESBuild. See: -// https://esbuild.github.io/api/#supported. -const supported = {}; - -// Async/Await can be downleveled so that ZoneJS can intercept. See: -// https://github.com/angular/angular-cli/blob/afe9feaa45913/packages/angular_devkit/build_angular/src/builders/browser-esbuild/index.ts#L313-L318. -if (downlevelAsyncAwait) { - supported['async-await'] = false; -} - -export default { - // Based on the CLI configuration: - // https://github.com/angular/angular-cli/blame/8089c9388056b3caaf56f981848aca94f022da73/packages/angular_devkit/build_angular/src/tools/esbuild/application-code-bundle.ts#L51. - conditions: ['es2022', 'es2020', 'es2015', 'module'], - // Note: ES2015 main condition is needed for `rxjs@v6`. - mainFields: ['fesm2022', 'es2022', 'es2020', 'es2015', 'module', 'main'], - // Addition of `.mjs` to the non-jsx defaults. - // https://esbuild.github.io/api/#resolve-extensions - resolveExtensions: ['.mjs', '.js', '.json'], - // Bundling specs may result in classes being aliased to avoid collisions. e.g. when - // everything is bundled into a single AMD bundle. To avoid test failures for assertions - // on symbol names, we instruct ESBuild to keep original names. See: - // https://esbuild.github.io/api/#keep-names. - keepNames: true, - supported, - plugins, -}; diff --git a/tools/jasmine/old-spec-bundling/spec-entrypoint.bzl b/tools/jasmine/old-spec-bundling/spec-entrypoint.bzl deleted file mode 100644 index f4538fd16..000000000 --- a/tools/jasmine/old-spec-bundling/spec-entrypoint.bzl +++ /dev/null @@ -1,106 +0,0 @@ -load("@aspect_rules_js//js:providers.bzl", "JsInfo", "js_info") -load("@rules_nodejs//nodejs:providers.bzl", "JSModuleInfo") - -def _is_non_external_file_with_suffix(file, suffix): - """Gets whether the given file is a non-external file with the given suffix.""" - basename = file.basename - - # External files (from other workspaces) are always skipped. - if (file.short_path.startswith("../")): - return False - - # `.js` or `.mjs` files will be imported in the entry-point. - return basename.endswith("%s.js" % suffix) or \ - basename.endswith("%s.mjs" % suffix) - -def _filter_files(files, filter_suffixes): - """Filters the given list of files to only contain files with the given suffixes.""" - result = [] - for file in files: - for suffix in filter_suffixes: - if _is_non_external_file_with_suffix(file, suffix): - result.append(file) - break - - return result - -def _create_entrypoint_file(base_package, spec_files, bootstrap_files): - """Creates the contents of the spec entry-point ESM file. - - The file will import all individual bootstrap and spec files so that - these are bundled and loaded by NodeJS or the Karma browser.""" - - output = "" - for file in bootstrap_files + spec_files: - base_dir_segments = "/".join([".."] * len(base_package.split("/"))) - output += """import "%s/%s";\n""" % (base_dir_segments, file.short_path) - return output - -def _spec_entrypoint_impl(ctx): - output = ctx.actions.declare_file("%s.mjs" % ctx.attr.name) - spec_all_deps = [] - bootstrap_direct_deps = [] - bootstrap_all_deps = [] - - for dep in ctx.attr.deps: - if JsInfo in dep: - spec_all_deps.append(dep[JsInfo].transitive_sources) - spec_all_deps.append(dep[JsInfo].npm_sources) - elif JSModuleInfo in dep: - spec_all_deps.append(dep[JSModuleInfo].sources) - else: - spec_all_deps.append(dep[DefaultInfo].files) - - for dep in ctx.attr.bootstrap: - if JsInfo in dep: - bootstrap_all_deps.append(dep[JsInfo].transitive_sources) - bootstrap_all_deps.append(dep[JsInfo].npm_sources) - bootstrap_direct_deps.append(dep[JsInfo].sources) - elif JSModuleInfo in dep: - bootstrap_all_deps.append(dep[JSModuleInfo].sources) - bootstrap_direct_deps.append(dep[JSModuleInfo].direct_sources) - else: - bootstrap_all_deps.append(dep[DefaultInfo].files) - bootstrap_direct_deps.append(dep[DefaultInfo].files) - - # Note: `to_list()` is an expensive operation but we need to do this for every - # dependency here in order to be able to filter out spec files from depsets. - all_spec_files = depset(transitive = spec_all_deps).to_list() - spec_files = _filter_files(all_spec_files, ["spec", "test"]) - - # Note: `to_list()` is an expensive operation but we need to do this for every - # dependency here in order to be able to filter out spec files from depsets. - direct_bootstrap_files = depset(transitive = bootstrap_direct_deps).to_list() - - # Filter to only js and mjs files, we can't always define what the name of the files - # needed for bootstrapping are so we rely on the user to provide the exact list. - bootstrap_files = _filter_files(direct_bootstrap_files, [""]) - - ctx.actions.write( - output = output, - content = _create_entrypoint_file(ctx.label.package, spec_files, bootstrap_files), - ) - - out_depset = depset([output]) - transitive_deps = depset(transitive = [out_depset] + spec_all_deps + bootstrap_all_deps) - - return [ - DefaultInfo(files = out_depset), - js_info( - target = ctx.label, - sources = out_depset, - transitive_sources = transitive_deps, - ), - JSModuleInfo( - direct_sources = out_depset, - sources = transitive_deps, - ), - ] - -spec_entrypoint = rule( - implementation = _spec_entrypoint_impl, - attrs = { - "deps": attr.label_list(allow_files = True, mandatory = True), - "bootstrap": attr.label_list(allow_files = True, mandatory = True), - }, -) diff --git a/tools/jasmine/old-spec-bundling/spec_bundle.bzl b/tools/jasmine/old-spec-bundling/spec_bundle.bzl deleted file mode 100644 index 89acccf31..000000000 --- a/tools/jasmine/old-spec-bundling/spec_bundle.bzl +++ /dev/null @@ -1,153 +0,0 @@ -load("@build_bazel_rules_nodejs//:index.bzl", "js_library") -load("//tools/esbuild/old-esbuild:index.bzl", "esbuild", "esbuild_amd", "esbuild_config", "esbuild_esm_bundle") -load("//tools/jasmine/old-spec-bundling:spec-entrypoint.bzl", "spec_entrypoint") - -def spec_bundle( - name, - deps, - platform, - bootstrap = [], - run_angular_linker = False, - linker_unknown_declaration_handling = None, - target = "es2022", - # For ZoneJS compatibility, async/await is downleveled. - downlevel_async_await = True, - external = [], - workspace_name = None): - """Macro that will bundle all test files with their respective transitive dependencies. - Bundled specs end up in a single bundle file that can be loaded within Karma or NodeJS directly. - This is helpful as Angular framework packages do not ship UMD files and to avoid overall - complexity with maintaining a runtime loader such as RequireJS or SystemJS. - Args: - name: Name of the spec bundle target - deps: Targets that contain all spec files. Files ending with `spec.js` - are picked up. - platform: Platform for which spec should be bundled. i.e. `node`, `browser` or `cjs-legacy`. - bootstrap: Targets providing bootstrap scripts that run before the specs. Files - ending with `init.js` are picked up. - target: Target ECMAScript to use for the specs bundle. - run_angular_linker: Whether the Angular linker should process the bundled code. - downlevel_async_await: Whether async/await native syntax should be downleveled. - linker_unknown_declaration_handling: Control how unknown partial declarations should be - treated. This passes through to the `unknownDeclarationVersionHandling` linker plugin option. - external: List of modules/packages which should not be bundled. - workspace_name: Workspace name that needs to be provided for the AMD module name. - """ - - is_browser_test = platform == "browser" - is_legacy_cjs = platform == "cjs-legacy" - is_node = platform == "node" - - package_name = native.package_name() - esbuild_attrs = dict() - - spec_entrypoint( - name = "%s_spec_entrypoint" % name, - deps = deps, - bootstrap = bootstrap, - testonly = True, - ) - - spec_bundle_config_file( - name = "%s_config_file" % name, - testonly = True, - output_name = "%s_config.mjs" % name, - run_angular_linker = run_angular_linker, - downlevel_async_await = downlevel_async_await, - linker_unknown_declaration_handling = linker_unknown_declaration_handling, - ) - - esbuild_config_deps = [] - if run_angular_linker or downlevel_async_await: - esbuild_config_deps = ["//shared-scripts/angular-optimization:js_lib"] - - esbuild_config( - name = "%s_config" % name, - config_file = ":%s_config_file" % name, - testonly = True, - deps = esbuild_config_deps, - ) - - if is_browser_test and not workspace_name: - fail("The spec-bundling target %s is declared as browser test. In order to be able " + - "to construct an AMD module name, the `workspace_name` attribute needs to be set.") - - esbuild_rule = None - - if is_browser_test: - esbuild_rule = esbuild_amd - amd_name = "%s/%s/%s" % (workspace_name, package_name, name + "_spec") - esbuild_attrs["platform"] = "browser" - esbuild_attrs["output"] = "%s_spec.js" % name - esbuild_attrs["module_name"] = amd_name - elif is_legacy_cjs: - esbuild_rule = esbuild - esbuild_attrs["format"] = "iife" - esbuild_attrs["platform"] = "node" - esbuild_attrs["output"] = "%s_spec.js" % name - elif is_node: - esbuild_rule = esbuild_esm_bundle - esbuild_attrs["platform"] = "node" - esbuild_attrs["output"] = "%s_spec.mjs" % name - - esbuild_rule( - name = "%s_bundle" % name, - testonly = True, - config = ":%s_config" % name, - entry_point = ":%s_spec_entrypoint" % name, - target = target, - deps = deps + [":%s_spec_entrypoint" % name], - link_workspace_root = True, - external = external, - **esbuild_attrs - ) - - js_library( - name = name, - testonly = True, - named_module_srcs = [":%s_bundle" % name], - ) - -def _spec_bundle_config_file_impl(ctx): - run_angular_linker = ctx.attr.run_angular_linker - downlevel_async_await = ctx.attr.downlevel_async_await - linker_unknown_declaration_handling = ctx.attr.linker_unknown_declaration_handling - - ctx.actions.expand_template( - template = ctx.file._template, - output = ctx.outputs.output_name, - substitutions = { - "TMPL_RUN_LINKER": "true" if run_angular_linker else "false", - "TMPL_DOWNLEVEL_ASYNC_AWAIT": "true" if downlevel_async_await else "false", - "TMPL_LINKER_UNKNOWN_DECLARATION_HANDLING": ("'%s'" % linker_unknown_declaration_handling) if linker_unknown_declaration_handling else "undefined", - }, - ) - -spec_bundle_config_file = rule( - implementation = _spec_bundle_config_file_impl, - doc = "Generates an ESBuild configuration file for bundling specs", - attrs = { - "run_angular_linker": attr.bool( - doc = "Whether the Angular linker should process all files.", - default = False, - ), - "downlevel_async_await": attr.bool( - doc = "Whether to downlevel async/await syntax.", - default = True, - ), - "output_name": attr.output( - mandatory = True, - doc = "Name of the file where the config should be written to.", - ), - "linker_unknown_declaration_handling": attr.string( - values = ["ignore", "warn", "error"], - doc = """Controls how unknown declaration versions should be handled by the Angular linker. - https://github.com/angular/angular/blob/f94c6f433dba3924b79f137cfcc49d2dfd4d679c/packages/compiler-cli/linker/src/file_linker/linker_options.ts#L27-L39. - """, - ), - "_template": attr.label( - allow_single_file = True, - default = "//tools/jasmine/old-spec-bundling:esbuild.config-tmpl.mjs", - ), - }, -) diff --git a/tools/ts_project_interop.bzl b/tools/ts_project_interop.bzl deleted file mode 100644 index b5d0f130e..000000000 --- a/tools/ts_project_interop.bzl +++ /dev/null @@ -1,174 +0,0 @@ -load("@aspect_rules_js//js:providers.bzl", "JsInfo", "js_info") -load("@build_bazel_rules_nodejs//:providers.bzl", "DeclarationInfo", "JSEcmaScriptModuleInfo", "JSModuleInfo", "LinkablePackageInfo") -load("@devinfra//bazel/ts_project:index.bzl", "strict_deps_test") -load("@rules_angular//src/ts_project:index.bzl", _ts_project = "ts_project") - -def _ts_deps_interop_impl(ctx): - types = [] - sources = [] - runfiles = ctx.runfiles(files = []) - for dep in ctx.attr.deps: - if not DeclarationInfo in dep: - fail("Expected target with DeclarationInfo: %s", dep) - types.append(dep[DeclarationInfo].transitive_declarations) - if not JSModuleInfo in dep: - fail("Expected target with JSModuleInfo: %s", dep) - sources.append(dep[JSModuleInfo].sources) - if not DefaultInfo in dep: - fail("Expected target with DefaultInfo: %s", dep) - runfiles = runfiles.merge(dep[DefaultInfo].default_runfiles) - - return [ - DefaultInfo(runfiles = runfiles), - ## NOTE: We don't need to propagate module mappings FORTUNATELY! - # because rules_nodejs supports tsconfig path mapping, given that - # everything is nicely compiled from `bazel-bin/`! - js_info( - target = ctx.label, - transitive_types = depset(transitive = types), - transitive_sources = depset(transitive = sources), - ), - ] - -ts_deps_interop = rule( - implementation = _ts_deps_interop_impl, - attrs = { - "deps": attr.label_list(providers = [DeclarationInfo], mandatory = True), - }, -) - -def _ts_project_module_impl(ctx): - # Forward runfiles. e.g. JSON files on `ts_project#data`. The jasmine - # consuming rules may rely on this, or the linker due to its symlinks then. - runfiles = ctx.attr.dep[DefaultInfo].default_runfiles - info = ctx.attr.dep[JsInfo] - - # Filter runfiles to not include `node_modules` from Aspect as this interop - # target is supposed to be used downstream by `rules_nodejs` consumers, - # and mixing pnpm-style node modules with linker node modules is incompatible. - filtered_runfiles = [] - for f in runfiles.files.to_list(): - if f.short_path.startswith("node_modules/"): - continue - filtered_runfiles.append(f) - runfiles = ctx.runfiles(files = filtered_runfiles) - - providers = [ - DefaultInfo( - runfiles = runfiles, - ), - JSModuleInfo( - direct_sources = info.sources, - sources = depset(transitive = [info.transitive_sources]), - ), - JSEcmaScriptModuleInfo( - direct_sources = info.sources, - sources = depset(transitive = [info.transitive_sources]), - ), - DeclarationInfo( - declarations = _filter_types_depset(info.types), - transitive_declarations = _filter_types_depset(info.transitive_types), - type_blocklisted_declarations = depset(), - ), - ] - - if ctx.attr.module_name: - providers.append( - LinkablePackageInfo( - package_name = ctx.attr.module_name, - package_path = "", - path = "%s/%s" % (ctx.bin_dir.path, ctx.label.package), - files = info.sources, - ), - ) - - return providers - -ts_project_module = rule( - implementation = _ts_project_module_impl, - attrs = { - "dep": attr.label(providers = [JsInfo], mandatory = True), - # Noop attribute for aspect propagation of the linker interop deps; so - # that transitive linker dependencies are discovered. - "deps": attr.label_list(), - # Note: The module aspect from consuming `ts_library` targets will - # consume the module mappings automatically. - "module_name": attr.string(), - "module_root": attr.string(), - }, -) - -def ts_project( - name, - module_name = None, - deps = [], - interop_deps = [], - tsconfig = None, - testonly = False, - visibility = None, - # TODO: Enable this for all `ts_project` targets at end of migration. - ignore_strict_deps = True, - enable_runtime_rnjs_interop = True, - rule_impl = _ts_project, - **kwargs): - # Pull in the `rules_nodejs` variants of dependencies we know are "hybrid". This - # is necessary as we can't mix `npm/node_modules` from RNJS with the pnpm-style - # symlink-dependent node modules. In addition, we need to extract `_rjs` interop - # dependencies so that we can forward and capture the module mappings for runtime - # execution, with regards to first-party dependency linking. - rjs_modules_to_rnjs = [] - if enable_runtime_rnjs_interop: - for d in deps: - if d.startswith("//:node_modules/"): - rjs_modules_to_rnjs.append(d.replace("//:node_modules/", "@npm//")) - if d.endswith("_rjs"): - rjs_modules_to_rnjs.append(d.replace("_rjs", "")) - - ts_deps_interop( - name = "%s_interop_deps" % name, - deps = [] + interop_deps + rjs_modules_to_rnjs, - visibility = visibility, - testonly = testonly, - ) - - rule_impl( - name = "%s_rjs" % name, - testonly = testonly, - declaration = True, - tsconfig = tsconfig, - visibility = visibility, - deps = [":%s_interop_deps" % name] + deps, - **kwargs - ) - - if not ignore_strict_deps: - strict_deps_test( - name = "%s_strict_deps_test" % name, - srcs = kwargs.get("srcs", []), - deps = deps, - ) - - ts_project_module( - name = name, - testonly = testonly, - visibility = visibility, - dep = "%s_rjs" % name, - # Forwarded dependencies for linker module mapping aspect. - # RJS deps can also transitively pull in module mappings from their `interop_deps`. - deps = [] + ["%s_interop_deps" % name] + deps, - module_name = module_name, - ) - -# Filter type provider to not include `.json` files. `ts_config` -# targets are included in `ts_project` and their tsconfig json file -# is included as type. See: -# https://github.com/aspect-build/rules_ts/blob/main/ts/private/ts_config.bzl#L55C63-L55C68. -def _filter_types_depset(types_depset): - types = [] - - for t in types_depset.to_list(): - if t.short_path.endswith(".json"): - continue - types.append(t) - - return depset(types)