This repository was archived by the owner on Sep 11, 2024. It is now read-only.
Prevent Cypress typechecking react-sdk components without strict mode#12053
Merged
Prevent Cypress typechecking react-sdk components without strict mode#12053
Conversation
This prevented us from switching to `forwardRef` in a bunch of places due to it behaving different with & without strict mode. Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
andybalaam
approved these changes
Dec 14, 2023
Member
andybalaam
left a comment
There was a problem hiding this comment.
Looks perfectly sensible, but I don't really understand it. Does this just remove things that fail the without-strict type check? Or does it turn off a check in some way?
Member
Author
|
The important bit is it ditches the SettingsStore import by ditching most of the code that needed it and stubbing the types for the rest. SettingsStore imports half the app which means that a load of our code (critically AccessibleButton) gets typechecked without strict mode if you import SettingsStore in Cypress. |
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
For https://github.com/element-hq/customer-retainer/issues/157
This prevented us from switching to
forwardRefin a bunch of places due to it behaving different with & without strict mode.This change is marked as an internal change (Task), so will not be included in the changelog.