Skip to content
New issue

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

Property names are translated incorrectly #249

Open
tonyneel923 opened this issue Nov 19, 2020 · 2 comments
Open

Property names are translated incorrectly #249

tonyneel923 opened this issue Nov 19, 2020 · 2 comments
Labels

Comments

@tonyneel923
Copy link

Versions of relevant software used
ts-protoc-gen@0.12.0

What happened
Any properties defined with an underscore are translated into typescript definitions with no underscore. Also any types that are arrays have the word List appended to the name.

What you expected to happen
I expect the property names to stay the same

How to reproduce it (as minimally and precisely as possible):
Any proto with underscores will work for ex:

message SubscriptionDaysPastDueCalculation {
    uint32 subscription_id = 1;
    uint32 days_past_due = 2;
}

@thesayyn
Copy link

This problem is not about this plugin. in fact, it is caused by the official protoc compiler itself because it generates fields as getter setter methods so this plugin has to match that scheme.

You can solve this issue by using another plugin that solves this problem.

See: https://github.com/thesayyn/protoc-gen-ts and thesayyn/protoc-gen-ts#39

@stale
Copy link

stale bot commented Apr 17, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Apr 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants