Skip to content
This repository was archived by the owner on Jan 19, 2023. It is now read-only.

Reset didUnmount flag when component is mounted #591

Closed
wants to merge 1 commit into from
Closed

Reset didUnmount flag when component is mounted #591

wants to merge 1 commit into from

Conversation

igordanchenko
Copy link

This PR addresses the issue described in #589

Closes #589

@nvmnghia
Copy link

nvmnghia commented Jul 8, 2022

This seems to be awfully good & easy, compared to #632. Can you explain?

@igordanchenko
Copy link
Author

igordanchenko commented Jul 8, 2022

This PR addresses a very specific bug in the library that manifests itself in React 18 strict mode. The other ticket you mention aims to address a completely different issue, so I’m not sure how to compare these two PRs.

@nvmnghia
Copy link

nvmnghia commented Jul 8, 2022

@igordanchenko no the other issue also fix #589.

Is there anywhere can I read more about your fix?

@igordanchenko
Copy link
Author

@nvmnghia, #632 doesn't fix the underlying issue described in #589, it's just hiding the most obvious symptom. In fact, #632 breaks the lightbox in React 18 strict mode as the lightbox can be opened only once, and won't open again once closed.

You can read about React 18 strict mode component lifecycle changes here.

@fritz-c fritz-c closed this Jan 19, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Loading icon gets stuck in React 18 dev mode
3 participants