src/utils.js
function callAllEventHandlers(...fns) {
  return (event, ...args) =>
    fns.some(fn => {
      if (fn) {
        fn(event, ...args)
      }
      return (
        event.preventDownshiftDefault ||
        (event.hasOwnProperty('nativeEvent') &&
          event.nativeEvent.preventDownshiftDefault)
      )
    })
}
function callAllEventHandlers(...fns) {
  return (event, ...args) =>
    fns.some(fn => {
      if (fn) {
        fn(event, ...args)
      }
      return (
        event.preventDownshiftDefault ||
        (event.hasOwnProperty('nativeEvent') &&
          event.nativeEvent.preventDownshiftDefault)
      )
    })
}
function callAllEventHandlers ( ... fns ) { return ( event , ... args ) => fns . some ( fn => { if ( fn ) { fn ( event , ... args ) } return ( event . preventDownshiftDefault || ( event . hasOwnProperty ( 'nativeEvent' ) && event . nativeEvent . preventDownshiftDefault ) ) } ) }
This is intended to be used to compose event handlers.
They are executed in order until one of them sets
`event.preventDownshiftDefault = true`.
@param {...Function} fns the event handler functions
@return {Function} the event handler to add to an element
This is intended to be used to compose event handlers . They are executed in order until one of them sets event . preventDownshiftDefault = true .