generator-effective
Version:
a opinionated and progressive generator to make package.json and thousands of configs effective
17 lines (14 loc) • 417 B
text/typescript
import { handleUnaryCall } from 'grpc';
import { <%= requestType %>, <%= responseType %> } from '<%= pbPath %>';
/**
* Implements the <%= method %> RPC method.
*/
const <%= method %>: handleUnaryCall<<%= requestType %>, <%= responseType %>> = (
call,
callback
) => {
// const { request, metadata } = call;
const reply = new <%= responseType %>();
callback(null, reply);
};
export default <%= method %>;