mirror of
https://github.com/roleypoly/roleypoly.git
synced 2025-06-17 01:59:08 +00:00
chore: restructure bazel macros
This commit is contained in:
parent
a33aa3841c
commit
a0b4392b05
54 changed files with 80 additions and 56 deletions
20
hack/bazel/js/react.bzl
Normal file
20
hack/bazel/js/react.bzl
Normal file
|
@ -0,0 +1,20 @@
|
|||
load("@npm//@bazel/typescript:index.bzl", "ts_library")
|
||||
load("//hack/bazel:utils.bzl", "render_deps")
|
||||
|
||||
def react_library(name, deps = [], **kwargs):
|
||||
ts_library(
|
||||
name = name,
|
||||
srcs = native.glob(
|
||||
[
|
||||
"*.ts",
|
||||
"*.tsx",
|
||||
],
|
||||
exclude = native.glob([
|
||||
"*.spec.ts*",
|
||||
"*.story.tsx",
|
||||
"*.stories.tsx",
|
||||
]),
|
||||
),
|
||||
deps = render_deps(deps),
|
||||
**kwargs
|
||||
)
|
Loading…
Add table
Add a link
Reference in a new issue