/pfx-animation

Browser prefix helper for animation event

Primary LanguageJavaScriptMIT LicenseMIT

pfx-animation Build Status

Browser prefix helper for animation event

Install

$ npm install --save pfx-animation

Usage

const animation = require('pfx-animation');

const obj = document.querySelector('.move-obj');
obj.addEventListener(animation.end, () => {
	// the animation has finished
}, false);

API

animation

Object containing three properties, start, iteration, and end, that map to animationstart, animationiteration, and animationend, respectively, and include the correct vendor animation prefix (if needed).

License

MIT © Alex Cross