DEV Community

Discussion on: Collapsing Page Effect

Collapse
 
ekeijl profile image
Edwin • Edited

Looks really cool! But the demo link on NPM does not seem to work? You should add a Codesandbox example in this article.

Also, I think you can use DOMElement.contains() instead of the isDescendant function?

Collapse
 
johnnyfekete profile image
Johnny Fekete

Thanks Edwin,
Good points, I didn't know about the contains() method but seems like it could work, also has a great browser support!

Collapse
 
johnnyfekete profile image
Johnny Fekete

I tried to find which is the link that doesn't work. Is it the one saying try it yourself at the npm page?

If so, you need to click on the "Logout" button to see the animation