We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
If a proto definition contains a message like
message SomeMessage { string extension = 1; }
then the generated code contains something like
export class SomeMessage extends jspb.Message { // ... getExtension(): string; setExtension(value: string): SomeMessage; // ...
which are (invalid) implementations of the base methods
export abstract class Message { // ... getExtension<T>(fieldInfo: ExtensionFieldInfo<T>): T; setExtension<T>(fieldInfo: ExtensionFieldInfo<T>, value: T): void; // ...
The JS generator works around affected field names Extension and JsPbMessageId this by adding a $ to the getter/setter name: https://github.com/protocolbuffers/protobuf/blob/cf28f28347d65e352f429263500f982ae3e51aed/src/google/protobuf/compiler/js/js_generator.cc#L533-L536
Extension
JsPbMessageId
$
The text was updated successfully, but these errors were encountered:
Fixed with version v5.1.2.
v5.1.2
Sorry, something went wrong.
No branches or pull requests
If a proto definition contains a message like
then the generated code contains something like
which are (invalid) implementations of the base methods
The JS generator works around affected field names
Extension
andJsPbMessageId
this by adding a$
to the getter/setter name: https://github.com/protocolbuffers/protobuf/blob/cf28f28347d65e352f429263500f982ae3e51aed/src/google/protobuf/compiler/js/js_generator.cc#L533-L536The text was updated successfully, but these errors were encountered: