has-passive-events

1.0.0 • Public • Published

has-passive-events unstable Build Status

Check if event listener options are available on the current device. Try it out.

npm install has-passive-events

const hasPassive = require('has-passive-events')
 
hasPassive ? element.addEventListener('wheel', handler, {passive: true}) : element.addEventListener('wheel', handler)

If you find edge case, please address issues.

Readme

Keywords

Package Sidebar

Install

npm i has-passive-events

Weekly Downloads

185,951

Version

1.0.0

License

MIT

Last publish

Collaborators

  • dfcreative