-
Notifications
You must be signed in to change notification settings - Fork 27.2k
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
example: fix example error #54599
example: fix example error #54599
Conversation
Allow CI Workflow Run
Note: this should only be enabled once the PR is ready to go and can only be enabled by a maintainer |
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.
Orca Security Scan Summary
Status | Check | Issues by priority | |
---|---|---|---|
Passed | Secrets | 0 0 0 0 | View in Orca |
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.
Could you explain what's the error being addressed here?
I see you opened this on the Ant Design repo too, but there was no reasoning: ant-design/ant-design#44440
Hello, The client's cache should not be recreated |
@balazsorban44 @leerob @huozhi @timneutkens @styfle Can someone review this for me? thank you |
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 agree with @balazsorban44
This PR doesn't explain what the bug is or why this PR would fix it.
Furthermore, I can't find any documentation on this function besides https://ant-design.github.io/cssinjs#createcache
So asking for a review here is nearly impossible.
That said, since ant-design/ant-design#44440 was merged upstream then perhaps we should merge this too.
@styfle I'm sorry that I didn't explain the reason. My English is not good. In some special scenarios, the cache changes, leading to unexpected situations. For example, when the layout switches pages, the cache is not uninstalled, but the cache is re-created. , resulting in a miss when obtaining the component's style cache. To sum up, the cache should only be created once. |
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.
Thanks!
Looks like we can't merge because lint is failing
warning React Hook React.useMemo has an unnecessary dependency: 'createCache'. Either exclude it or remove the dependency array. Outer scope values like 'createCache' aren't valid dependencies because mutating them doesn't re-render the component react-hooks/exhaustive-deps
I have removed unnecessary dependencies, please check again, thank you |
example: fix example error