Re:Show HN: JSONSchema to TypeScript compiler
by bcherny on Wednesday April 26, 2017 @02:23AM
(#14200888)
Awesome work. Expressing concepts that TS's type system can't handle (eg. minimum) as comments is an approach that I didn't consider. So far I've been focused on the idea of generating decorators [0], but comments seem like a solid stopgap. Especially because they show up as tooltips in VSCode.
[0] https://github.com/bcherny/json-schema-to-typescript/issues/...
In case you need to do the reverse, for example model-first in typescript and want to generate JSONSchema:
Typescript Code to JSONSchema: https://github.com/YousefED/typescript-json-schema - started this long ago but some great contributors are leading it since!