-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[MPDX-8443] Upgrade TypeScript to the latest version #1194
Conversation
Required upgrade to the latest yarn v3 and @types/jest packages to fix type errors with describe/it/expect.
Preview branch generated at https://8443-upgrade-typescript.d3dytjb8adxkk5.amplifyapp.com |
Bundle sizes [mpdx-react]Compared against 95a5eae No significant changes found |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed the code. It looks great! thank you for upgrading TS. I'm waiting for it to rebuild so I can test the UI.
https://us-east-1.console.aws.amazon.com/amplify/apps/d3dytjb8adxkk5/branches/8443-upgrade-typescript/deployments#
.yarn/sdks/eslint/bin/eslint.js
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I assume you ran yarn self-update
on these files in the commit "Update yarn SDKs". If you manually did it, you are a beast; I would struggle.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Haha, no not manually. I ran yarn dlx @yarnpkg/sdks
.
@@ -80,7 +80,7 @@ describe('TasksDueThisWeek', () => { | |||
subject: '1 the quick brown fox jumps over the lazy dog', | |||
activityType: ActivityTypeEnum.PartnerCarePrayerRequest, | |||
contacts: { | |||
nodes: [{ hidden: true, name: 'Smith, Roger', id: '1' }], | |||
nodes: [{ name: 'Smith, Roger', id: '1' }], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What error caused you to remove these and the other fields from tests on other pages? Was it that they were not set up correctly to begin with?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mock fields I removed like this one aren't present on the query. Now TypeScript complains about them. I'm removing them since they don't do anything anyway.
It seems like there is a deployment issue. It could just be this Preview |
@dr-bizz Thanks for pointing that out. It's a yarn configuration issue. I'll request another review when I have it fixed. |
@@ -13,7 +13,6 @@ frontend: | |||
fi | |||
- echo "NEXTAUTH_URL=$NEXTAUTH_URL" >> .env | |||
- echo "NODE_ENV=$NODE_ENV" >> .env | |||
- yarn set version 3.3.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you look in the logs, yarn -v
shows that yarn is correctly running version 3.8.6 after this change. Removing this line means one fewer places to have to update when we update yarn.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great
Description
@types/jest
would work properlyMPDX-8443
Checklist: