[NO QA] feat: Add tsgo for faster dev type checking #83228
Conversation
Install @typescript/native-preview and configure `npm run typecheck-tsgo` with a dedicated tsconfig.tsgo.json. Enables the experimental Go-based TypeScript compiler for faster type checking during development.
… assignment in IOU
|
|
# Conflicts: # package.json # src/libs/API/types.ts
|
@DylanDylann Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid: mWeb ChromeiOS: HybridAppiOS: mWeb SafariMacOS: Chrome / Safari |
|
@dariusz-biela It's so fast now |
|
PR doesn’t need product input as a dev tooling PR. Unassigning and unsubscribing myself. |
Codecov Report✅ Changes either increased or maintained existing code coverage, great job!
|
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚧 @roryabraham has triggered a test Expensify/App build. You can view the workflow run here. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
🚀 Deployed to staging by https://github.com/roryabraham in version: 9.3.27-0 🚀
|
|
🚀 Deployed to production by https://github.com/blimpich in version: 9.3.27-8 🚀
|
Explanation of Change
Add
@typescript/native-preview(tsgo) as a dev dependency withnpm run typecheck-tsgocommand for faster type checking during development. Includes a dedicatedtsconfig.tsgo.jsonand fixes for existing type errors detected by tsgo.Benchmark (Expensify App):
Bugs fixed (detected by tsgo, silently accepted by tsc):
[src/ONYXKEYS.ts] Remove duplicate
VERIFY_3DS_SUBSCRIPTIONkey inOnyxValuesMapping[src/libs/API/types.ts] Remove duplicate command keys in
API/types.ts[src/libs/EmojiUtils.tsx] Add null check for
regexResult.indices[0]inEmojiUtils[src/libs/Navigation/types.ts] Remove duplicate
EXPENSIFY_CARDscreen params inNavigation/types.ts[src/libs/actions/IOU/index.ts] Remove unnecessary
@ts-expect-errordirectives and fixstatusNumassignment inIOU/index.ts[src/libs/actions/Policy/Policy.ts] Restructure conditional
OnyxUpdatespread to avoidundefinedinPolicy.ts[src/types/onyx/ReimbursementAccount.ts] Remove duplicate CORPAY field definitions in
ReimbursementAccount.ts[src/pages/signin/SignInPageLayout/BackgroundImage/index.tsx] Type lazy SVG import catch handlers in
BackgroundImage/index.tsx[src/components/MoneyRequestReportView/MoneyRequestReportActionsList.tsx] Import
ListRenderItemInfofrom main@react-native/virtualized-listsexportFixed Issues
$ #83349
Tests
N/A — dev tooling only, no runtime changes.
Offline tests
N/A
QA Steps
N/A — no user-facing changes. [No QA]
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.