When the message filed contains number it's name in the generated typescript is not consistent with the JSON Mapping done by the grpc-gateway runtime. See example below.
Example input message:
syntax = "proto3";
package example.v1;
message Example { string k8s_field = 1; }
Result:
/* eslint-disable */
// @ts-nocheck
/*
* This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
*/
export type Example = {
k8SField?: string
}
Expected result
export type Example = {
k8sField?: string
}
Generator uses fieldName function that effectively uses strcase.ToLoweCamel that also uppers the case of characters after any number.
When the message filed contains number it's name in the generated typescript is not consistent with the JSON Mapping done by the
grpc-gatewayruntime. See example below.Example input message:
Result:
Expected result
Generator uses
fieldNamefunction that effectively usesstrcase.ToLoweCamelthat also uppers the case of characters after any number.