export const bindEvent = ( dom , name , func , useCapture ) => { if ( dom . addEventListener ) { dom . addEventListener ( name , func , useCapture ) ; } else if ( dom . attachEvent ) { dom . attachEvent ( `on${ name }` , func , useCapture ) ; } } ; export const removeEvent = ( dom , name , func , useCapture ) => { if ( dom . removeEventListener ) { dom . removeEventListener ( name , func , useCapture ) ; } else if ( dom . detachEvent ) { dom . detachEvent ( `on${ name }` , func , useCapture ) ; } } ;