tristen / hoverintent

:mouse: Fire mouse events when a user intends it
https://tristen.ca/hoverintent/
MIT License
331 stars 54 forks source link

Add reset option to support dispatching onOut event when removing #33

Open seriouslysean opened 3 years ago

seriouslysean commented 3 years ago

Solves https://github.com/tristen/hoverintent/issues/21 -- alternate solve to what #32 is doing.

--

This PR adds the option to reset the hoverintent usage when remove takes places. This optionally fires the onOut event to do any sort of cleanup required. The option is passed as a parameter to the remove event to keep things colocated where possible.

Also added an .nvmrc file with the recommended node version and the proper engine entries to the package.json files as the build function only ran in node version < 11.