-
-
Notifications
You must be signed in to change notification settings - Fork 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
Latest preact version breaks @radix-ui/react-switch and application #4590
Comments
Hey, Mind adding a reproduction as the issue template demands? I'm mainly asking because when I leverage the basic version of this library in 10.24.3 it seems to also bail out 😅 afaict this can never work for > 2 clicks due to an erroneous use of a Property Setter on an HTML node. const input = ref.current;
const inputProto = window.HTMLInputElement.prototype;
const descriptor = Object.getOwnPropertyDescriptor(inputProto, "checked");
const setChecked = descriptor.set;
if (prevChecked !== checked && setChecked) {
const event = new Event("click", { bubbles });
setChecked.call(input, checked);
console.log('dispatching event')
input.dispatchEvent(event);
} |
@JoviDeCroock Hi, I tried to reproduce the problem in StackBlitz with pure Switch usage and I failed. I have a really large and complex application. After updating to 10.25.0/10.25.1, my application began to freeze at the time of rendering the UI. Experimentally, commenting on the components, I found that the hang causes @radix-ui/switch. Asynchronous operations, memoization, fragments, or suspense may be affected. I need a little more time to reproduce the problem in a clean environment. |
As it turned out, the problem was not with @radix-ui/*. I wrapped all dynamic component inserts in Suspense and the problem was resolved.
I think, this issue can be closed |
preact@^10.25.0 (it has also been checked on 10.25.1)
Describe the bug
When trying to create a component, the page freezes. There is no memory leak in devtools, but the rendering process does not continue
Everything works fine on version 10.24.3
The text was updated successfully, but these errors were encountered: