chore: generate declarations with tsgo (TypeScript 7 native compiler)#4
Closed
aojunhao123 wants to merge 2 commits into
Closed
chore: generate declarations with tsgo (TypeScript 7 native compiler)#4aojunhao123 wants to merge 2 commits into
aojunhao123 wants to merge 2 commits into
Conversation
|
React Doctor found no new issues. 🎉 Reviewed by React Doctor for commit |
Owner
Author
|
Superseded by upstream react-component#60 (this one had the wrong base branch). |
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
Generate
.d.tswith the tsgo (TypeScript 7 native) compiler viadts.compiler: 'tsgo'.Why
father's default dts path runs its own bundled
typescript@5.4.2, independent of the project's compiler. Under this project's (non-strict) tsconfig, 5.4.2 fails to narrow theListyScrollToConfigunion inVirtualListscrollTo, sopnpm compilebreaks even though the editor /tsc(6.x) is happy. tsgo runs the TS7 native compiler, which narrows correctly and emits declarations roughly 10x faster.Notes
@typescript/native-previewis the compiler tsgo resolves; the project'stypescript@6is major < 7 and is skipped by father's resolver.rootDirstrictly, and father hands it the full tsconfig file list (includingtests/**), which tripsTS6059.tsconfig.build.jsonscopes the build tosrc/and is wired in throughFATHER_TSCONFIG_NAME; the main tsconfig (editor / jest) is untouched.@typescript/native-previewis a preview build — treat this as opt-in until father ships stable TS7 support.🤖 Generated with Claude Code