Generating Documentation from Schema Unions in TypeScript
Hey, I wonder if there's any prior art related to generating documentation from a (union of) Schema(s)? For example:
const Red = S.TaggedStruct('Red', { roses: S.Array(S.Unknown) }).annotations({ identifier: 'Red' })
const Blue = S.TaggedStruct('Blue', { violets: S.Array(S.Unknown) }).annotations({ identifier: 'Blue' })
const Color = S.Union(Red, Blue).annotations({ identifier: 'Color', description: 'A color from that poem' });
toMarkdown(Color) == `
# Color
A color from that poem
## Red
- roses: Array<unknown>
## Blue
- violets: Array<unknown>`