3 ms·
Hey, nice work on openapi-code-generator, its output is very nice. I think you could probably package it up as a TypeSpec emitter without too much difficulty, b
by bterlson 3y ago
Hey, nice work on openapi-code-generator, its output is very nice. I think you could probably package it up as a TypeSpec emitter without too much difficulty, by emitting OpenAPI and feeding it to your generator. I am doing a similar thing for a Kiota emitter I'm working on. We recently added an API to get the OpenAPI as a JS object which may be of help in this quest:
https://typespec.io/docs/libraries/openapi3/reference/js-api/functions/getOpenAPI3 https://typespec.io/docs/libraries/openapi3/reference/js-api...
- mnahkies 3y agoThanks for the reference! This is essentially what I had in mind - allow typespec as input and transparently convert to openapi then feed to the existing process. I suspect there's potential for some loss of information with this approach (I'm relatively new to typespec so not sure) but I plan to do this as a first pass and then consider a more direct approach later if I see gaps worth fixing.