Skip to content
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

Usage with preact #28

Open
danielgek opened this issue Aug 21, 2018 · 2 comments
Open

Usage with preact #28

danielgek opened this issue Aug 21, 2018 · 2 comments

Comments

@danielgek
Copy link

danielgek commented Aug 21, 2018

Hi, i'm trying to use this with preact and i get an error described here
If outDelay is 0 the bug doesn't happen, when you add a delay it triggers the above error

The error is in this line

Changing the if condition to fixes the problem:

if (!modals || modals.length === 0) {
  return null;
}

I don't know if this is the right fix or if it's another thing that's not right
@davidmfoley what do you think ?
Also @developit i saw that you answered that stackoverflow question, do you have any idea ?

@davidmfoley
Copy link
Owner

I don't know enough about preact to be able to help out here. Might it have something to do with preact's handling of a component where the state is initialized "inline" rather than via an explicit setState call?

@davidmfoley
Copy link
Owner

davidmfoley commented Oct 1, 2018

I think I found and fixed this bug in version 1.5.1. Please let me know if you get a chance to test it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants