Providers¶
-
class
GrpcProvider
(config)¶ exported from
providers/grpc
Provider for standard GRPC connections over HTTP2. This is only compatible with Node.js environments.
import { GrpcProvider } from '@herajs/client'; const provider = new GrpcProvider({url: 'localhost:7845'});
Arguments: - config (providers/grpc.GrpcProviderConfig) –
-
class
GrpcWebProvider
(config)¶ exported from
providers/grpc-web
Provider for GRPC-WEB connections over HTTP. This is compatible with Web browsers. Note that the transport is considerably slower than over standard GRPC.
import { GrpcWebProvider } from '@herajs/client'; const provider = new GrpcWebProvider({url: 'http://localhost:7845'});
Arguments: - config (providers/grpc-web.GrpcWebProviderConfig) –