移动端事件监听性能优化
try { const opts = {} Object.defineProperty(opts, 'passive', ({ get () { /* istanbul ignore next */ supportsPassive = true } } : Object)) window.addEventListener('test-passive', null, opts) } catch (e) {}



参考:https://juejin.im/entry/59dd88ec51882578ce26e6c7

确认 取消