sachinchoolur / lightgallery.js

Full featured JavaScript image & video gallery. No dependencies
https://sachinchoolur.github.io/lightgallery.js/
Other
5.3k stars 596 forks source link

Add support for onBeforeDestroy and onAfterDestroy events #114

Closed talawahtech closed 3 years ago

talawahtech commented 5 years ago

This allows you to take actions (like creating a new gallery) only after the gallery has been fully destroyed

AndreasHerss commented 4 years ago

This would be a nice addition @sachinchoolur.

I needed this today, as i had to destroy the gallery and create a new, but if i do it too fast, it creates the gallery, but doesn't show it.. so i had to add a setTimeout with a 300 millisecond delay between to make it work.

stale[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had recent activity. If the issue is still valid for version 2.x, please re-open. Apologize for not responding on time. Thank you for your contributions.