EthanThatOneKid / github_api_types

Type definitions for the GitHub API (https://docs.github.com/en/rest).
Do What The F*ck You Want To Public License
1 stars 1 forks source link

Tree-shakable interfaces #9

Open EthanThatOneKid opened 1 year ago

EthanThatOneKid commented 1 year ago

I won’t make a Deno script that generates the types from scratch at the moment. I’ve tried it and determined that the OpenAPI JSON is a lot for to parse. What I am more willing to do is transform the operations interface generated by the openapi-typescript tool.

_Originally posted by @EthanThatOneKid in https://github.com/EthanThatOneKid/github_api_types/issues/1#issuecomment-1510054491_

EthanThatOneKid commented 1 year ago

Instead of generating all of the TypeScript with ts-morph directly from the OpenAPI files, I think deterministically transforming the generated operations interface into uniquely named, tree-shakable types could do the trick.