You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There seems to be a fair bit of functional overlap with Typeshare in terms of emitting type declarations from Rust types. Typeshare scopes a broader set of target languages and currently only support structs and enums.
One benefit typeshare has is that it doesn't seem to depend on macro expansion when emitting the declaration file (in typeshare's perspective it's really just a ts file, but the interpretation is mostly the same), which skips Rust compilation. That detail is what got me to write up this issue in the first place. We have a dedicated GitHub Action workflow for type checking and we'd like to generate the declaration file without checking it into source control - in fact, it's not a single project but rather tens of projects. We would spend a significant amount of (unnecessary I'd argue) time building with napi just to generate a declaration file.
Have any considerations been made to offload the .d.ts-file generation to the typeshare project by contributing the parts that it lacks which this project has, e.g. traits, assuming they (1Password) are interested in extending their featureset? It should be noted that both projects use syn to parse Rust, so the parsing implementations look familiar.
The text was updated successfully, but these errors were encountered:
There seems to be a fair bit of functional overlap with Typeshare in terms of emitting type declarations from Rust types. Typeshare scopes a broader set of target languages and currently only support structs and enums.
One benefit typeshare has is that it doesn't seem to depend on macro expansion when emitting the declaration file (in typeshare's perspective it's really just a ts file, but the interpretation is mostly the same), which skips Rust compilation. That detail is what got me to write up this issue in the first place. We have a dedicated GitHub Action workflow for type checking and we'd like to generate the declaration file without checking it into source control - in fact, it's not a single project but rather tens of projects. We would spend a significant amount of (unnecessary I'd argue) time building with napi just to generate a declaration file.
Have any considerations been made to offload the .d.ts-file generation to the typeshare project by contributing the parts that it lacks which this project has, e.g. traits, assuming they (1Password) are interested in extending their featureset? It should be noted that both projects use
syn
to parse Rust, so the parsing implementations look familiar.The text was updated successfully, but these errors were encountered: