JSPM

prefixed-event

1.0.4
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 37
  • Score
    100M100P100Q74749F
  • License MIT

Add and remove event listeners for events that require vendor prefixes.

Package Exports

  • prefixed-event

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (prefixed-event) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

prefixed-event

Simplifies addEventListener and removeEventListener for events that require vendor prefixes.

Adapted from Craig Buckler's article.

Install

npm install prefixed-event

Usage

var prefixedEvent = require('prefixed-event')
var el = document.querySelector('.something-animated')

function doSomething(){
    prefixedEvent.remove(el, 'AnimationEnd', doSomething)
}

prefixedEvent.add(el, 'AnimationEnd', doSomething )

Testing

  • Uses browserify
  • Uses testem

make test