forked from stackb/rules_proto
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathBUILD.bazel
54 lines (50 loc) · 1.21 KB
/
BUILD.bazel
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
load("//:plugin.bzl", "proto_plugin")
proto_plugin(
name = "closure",
options = [
"import_style=closure",
"mode=grpcweb",
],
outputs = [
"_grpc_web_pb.js",
],
tool = "@com_github_grpc_grpc_web//javascript/net/grpc/web:protoc-gen-grpc-web",
visibility = ["//visibility:public"],
)
proto_plugin(
name = "commonjs",
options = [
"import_style=commonjs",
"mode=grpcweb",
],
outputs = [
"_grpc_web_pb.js",
],
tool = "@com_github_grpc_grpc_web//javascript/net/grpc/web:protoc-gen-grpc-web",
visibility = ["//visibility:public"],
)
proto_plugin(
name = "commonjs_dts",
options = [
"import_style=commonjs+dts",
"mode=grpcweb",
],
outputs = [
"_grpc_web_pb.js",
"_pb.d.ts",
],
tool = "@com_github_grpc_grpc_web//javascript/net/grpc/web:protoc-gen-grpc-web",
visibility = ["//visibility:public"],
)
proto_plugin(
name = "ts",
options = [
"import_style=typescript",
"mode=grpcweb",
],
outputs = [
"_pb.d.ts",
],
tool = "@com_github_grpc_grpc_web//javascript/net/grpc/web:protoc-gen-grpc-web",
visibility = ["//visibility:public"],
)