tatethurston / TwirpScript

A protobuf RPC framework for JavaScript and TypeScript

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Enum methods with suffix ToInt not importeds

alexisvisco opened this issue · comments

Hi,

While generating a proto with a enum in another package, methods with ToInt arn't imported.

Example https://github.com/alexisvisco/protocol-example/tree/enum-does-not-works

Hey @alexisvisco thanks for reporting. Could you give me a little more context here? Which file(s) should I be looking at?

https://github.com/alexisvisco/protocol-example/blob/enum-does-not-works/protos/leads/v1/leads.proto#L85

When you are generating the code you will see an error in your editor, or when building typescript files

Ah, got it. Thanks @alexisvisco, I see what's going on here. This is a regression I introduced when I migrated to a string representation for enums.