Skip to content

Investigate replacing typescript-json-schema with a tree-sitter-based TypeScript front end #3069

Description

@schani

Split out from discussion on #3037.

quicktype-typescript-input currently converts .ts sources to JSON Schema via the third-party typescript-json-schema package. Two recurring problems with this approach:

  • It pins us to a specific TypeScript compiler version, and upgrades have repeatedly required forking/patching (e.g. bigint handling, JSDoc @type braces, enum member names).
  • The conversion is increasingly patched with post-processing passes on top of the generated schema, which is becoming hard to maintain.

We should investigate whether a tree-sitter-based parser for the TypeScript input could give us a lighter, version-independent front end that produces quicktype-core input directly, and what functionality (type resolution, Required<>/utility types, cross-file refs) we would lose or have to reimplement.

This is an investigation/design task, not a committed rewrite.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions