tree: cb7135319b17fd9ffbc537f96c09a36be7de786e
  1. example/
  2. BUILD.bazel
  3. defs.bzl
  4. deps.bzl
  5. grpcjs_grpc_compile.bzl
  6. grpcjs_grpc_library.bzl
  7. README.md
  8. repositories.bzl
github.com/stackb/grpc.js/README.md

grpc.js rules

RuleDescription
grpcjs_grpc_compileGenerates protobuf closure grpc .js files
grpcjs_grpc_libraryGenerates protobuf closure library .js files

grpcjs_grpc_compile

Generates protobuf closure grpc .js files

WORKSPACE

load("@rules_proto_grpc//github.com/stackb/grpc.js:repositories.bzl", rules_proto_grpc_grpcjs_repos="grpcjs_repos")

rules_proto_grpc_grpcjs_repos()

BUILD.bazel

load("@rules_proto_grpc//github.com/stackb/grpc.js:defs.bzl", "grpcjs_grpc_compile")

grpcjs_grpc_compile(
    name = "greeter_grpc.js_grpc",
    deps = ["@rules_proto_grpc//example/proto:greeter_grpc"],
)

Attributes

NameTypeMandatoryDefaultDescription
depslist<ProtoInfo>true[]List of labels that provide a ProtoInfo (such as native.proto_library)
verboseintfalse0The verbosity level. Supported values and results are 1: show command, 2: show command and sandbox after running protoc, 3: show command and sandbox before and after running protoc, 4. show env, command, expected outputs and sandbox before and after running protoc

grpcjs_grpc_library

Generates protobuf closure library .js files

WORKSPACE

load("@rules_proto_grpc//github.com/stackb/grpc.js:repositories.bzl", rules_proto_grpc_grpcjs_repos="grpcjs_repos")

rules_proto_grpc_grpcjs_repos()

load("@io_bazel_rules_closure//closure:defs.bzl", "closure_repositories")

closure_repositories()

BUILD.bazel

load("@rules_proto_grpc//github.com/stackb/grpc.js:defs.bzl", "grpcjs_grpc_library")

grpcjs_grpc_library(
    name = "greeter_grpc.js_library",
    deps = ["@rules_proto_grpc//example/proto:greeter_grpc"],
)

Attributes

NameTypeMandatoryDefaultDescription
depslist<ProtoInfo>true[]List of labels that provide a ProtoInfo (such as native.proto_library)
verboseintfalse0The verbosity level. Supported values and results are 1: show command, 2: show command and sandbox after running protoc, 3: show command and sandbox before and after running protoc, 4. show env, command, expected outputs and sandbox before and after running protoc