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

Use same options in proto compile and load #90

Merged
merged 1 commit into from
Feb 29, 2024
Merged

Use same options in proto compile and load #90

merged 1 commit into from
Feb 29, 2024

Conversation

paskozdilar
Copy link

First of all, thank you for this example repository! I've been using it as a reference countless times while writing TypeScript services.


I've noticed a small footgun in proto-loader example:

When using the flags --oneofs for the build:proto step, the generated code provides a virtual property for each oneof message type.
However, if the same option is not used in loadSync method, the virtual property is always undefined.

I've added the options to match those used in the build:proto, so people in the future will avoid the same mistake.

@badsyntax
Copy link
Owner

Wasn't aware of this, thank you!

@badsyntax badsyntax merged commit 52d1394 into badsyntax:master Feb 29, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants