()
| 221 | let _supportsPassive; |
| 222 | |
| 223 | const supportsPassive = function() { |
| 224 | if (typeof _supportsPassive !== 'boolean') { |
| 225 | _supportsPassive = false; |
| 226 | try { |
| 227 | const opts = Object.defineProperty({}, 'passive', { |
| 228 | get() { |
| 229 | _supportsPassive = true; |
| 230 | } |
| 231 | }); |
| 232 | |
| 233 | window.addEventListener('test', null, opts); |
| 234 | window.removeEventListener('test', null, opts); |
| 235 | } catch (e) { |
| 236 | // disregard |
| 237 | } |
| 238 | } |
| 239 | |
| 240 | return _supportsPassive; |
| 241 | }; |
| 242 | |
| 243 | /** |
| 244 | * Touch events Chrome expects to be passive |
no outgoing calls
no test coverage detected
searching dependent graphs…