-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Support TypeScript for React components #12696
Conversation
Same treatment as matrix-org/matrix-react-sdk#4203
cc86cb2
to
798d4da
Compare
@@ -94,7 +94,7 @@ | |||
"@babel/preset-typescript": "^7.7.4", | |||
"@babel/register": "^7.7.4", | |||
"@babel/runtime": "^7.7.6", | |||
"@types/react": "^16.9.17", | |||
"@types/react": "16.9", |
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.
Why is this no longer a caret dependency (also on matrix-org/matrix-react-sdk#4203)?
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.
because yarn is awful for two reasons: it doesn't default to caret when installing things, and we should be pinning our types to our react version. 16.9
still gets resolved the same as 16.9.x
, which is compatible with carets.
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.
So 16.9
, ^16.9
^16.9.0
all get resolved differently? Also, if this is the correct treatment for @types/react
, should @types/react-dom
below also be updated?
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.
Same treatment as matrix-org/matrix-react-sdk#4203