Repository navigation
Conversation
- Migrate AST consumers/factories to `typescript/ast` and `typescript/ast/factory` where the TS 7 API is stable - Keep printer/JSDoc-dependent modules on the `typescript.ts` adapter - Make the plugin a native ESM package, bundled with tsup (same as the CLI) so source imports stay extensionless - Add CJS interop wrappers for `case`, `lodash` and `pluralize` - Harden CLI `getText` with an explicit string-literal check Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this delivers
Everything for the TypeScript 7 migration that does not depend on the native printer, so the remaining work is small once upstream lands.
typescript/ast,typescript/ast/factory) for the stable parts: import factories (phaseModifier), import-usage analysis,getOperationTypes,getRequestBodyType,getDataResponseType,schemaToEnumDeclaration, native scanner inisValidIdentifier.plugins/typescript/src/typescript.ts. Removing it later is a mechanical follow-up."type": "module"), bundled withtsupexactly like the CLI. Source imports stay extensionless (no.jssuffixes); the plugin tsconfig now inherits the rootBundlerresolution. TS 7 only exposes ESM subpaths, so the old Node16/CJS emit could not build.case,lodash,pluralize(named imports from these CJS packages fail in Node ESM).getTextvalidates string literals and throwsTypeErrorinstead of silently returning"";updateConfigreuses it.Not included / blocked on upstream
getVariablesType: nativecreatePropertySignatureDeclarationcurrently requires an initializer; stays on the adapter.Dependencies
feat(printer): implement JSDoc node emission in AST printer(open, targetsrelease-7.1). This is the release-7.1 change this stack waits on; once it ships, the adapter can be dropped.Validation
pnpm check:types✅pnpm test --run– 28 files / 244 tests ✅pnpm build✅plugins/typescript/libimported in plain Node ESM andgenerateSchemaTypesrun end-to-end ✅