pfx-transition
v1.0.0
Published
Browser prefix helper for transition event
Downloads
4
Maintainers
Readme
pfx-transition
Browser prefix helper for transition event
Install
$ npm install --save pfx-transition
Usage
const transition = require('pfx-transition');
const slides = document.querySelectorAll('.slide');
slides.forEach(slide => {
slide.addEventListener(transition.end, () => {
// the transition has finished
}, false);
});
API
transition
Object containing two properties, start
and end
, that map to transitionstart and transitionend, respectively, and include the correct vendor transition prefix (if needed).
License
MIT © Alex Cross