Closed
Description
THIS IS BREAKING CHANGE
What is this change about?
TSImportType
has boolean property isTypeOf
that is inconsistent with other usages of typeof
within AST structure.
isTypeOf
property is unique (not used anywhere else in code)
type x = typeof import('x')
TSImportType:
- isTypeOf: boolean
type x = typeof window
TSTypeQuery:
- exprName: Identifier
Why we should change it?
- Improve consistency of ast structure.
- Align generated structure with babel representation
- Allow consumers (eg. prettier) to correctly place comment - link
typeof /* comment */ import('x')