mirror of
https://github.com/angular/angular-cli.git
synced 2025-05-16 10:33:43 +08:00
build: migrate @angular/pwa to npm_package
This allows us to use the package in the RJS pnpm workspace.
This commit is contained in:
parent
a7155f6365
commit
e182d15f00
@ -4,28 +4,32 @@
|
||||
# found in the LICENSE file at https://angular.dev/license
|
||||
|
||||
load("@npm//@bazel/jasmine:index.bzl", "jasmine_node_test")
|
||||
load("//tools:defaults.bzl", "pkg_npm")
|
||||
load("//tools:interop.bzl", "ts_project")
|
||||
load("//tools:defaults2.bzl", "npm_package", "ts_project")
|
||||
load("//tools:ts_json_schema.bzl", "ts_json_schema")
|
||||
|
||||
licenses(["notice"])
|
||||
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
RUNTIME_ASSETS = glob(
|
||||
include = [
|
||||
"pwa/*.js",
|
||||
"pwa/*.mjs",
|
||||
"pwa/files/**/*",
|
||||
],
|
||||
) + [
|
||||
"package.json",
|
||||
"collection.json",
|
||||
"pwa/schema.json",
|
||||
]
|
||||
|
||||
ts_project(
|
||||
name = "pwa",
|
||||
srcs = [
|
||||
"pwa/index.ts",
|
||||
"//packages/angular/pwa:pwa/schema.ts",
|
||||
],
|
||||
data = [
|
||||
"collection.json",
|
||||
"pwa/schema.json",
|
||||
] + glob(
|
||||
include = [
|
||||
"pwa/files/**/*",
|
||||
],
|
||||
),
|
||||
data = RUNTIME_ASSETS,
|
||||
module_name = "@angular/pwa",
|
||||
deps = [
|
||||
"//:root_modules/@types/node",
|
||||
@ -63,16 +67,16 @@ genrule(
|
||||
cmd = "cp $(execpath //:LICENSE) $@",
|
||||
)
|
||||
|
||||
pkg_npm(
|
||||
name = "npm_package",
|
||||
npm_package(
|
||||
name = "pkg",
|
||||
pkg_deps = [
|
||||
"//packages/angular_devkit/schematics:package.json",
|
||||
"//packages/schematics/angular:package.json",
|
||||
],
|
||||
tags = ["release-package"],
|
||||
deps = [
|
||||
deps = RUNTIME_ASSETS + [
|
||||
":README.md",
|
||||
":license",
|
||||
":pwa",
|
||||
":pwa_rjs",
|
||||
],
|
||||
)
|
||||
|
Loading…
x
Reference in New Issue
Block a user