export const noop = ( ) => { } ; export const UNDEFINED = ( noop ( ) ) as undefined ; export const OBJECT = Object ; export const isUndefined = ( v ) : v is undefined => v === UNDEFINED ; export const isFunction = ( v ) : v is Function => typeof v == 'function' ; export const mergeObjects = ( a , b ) => OBJECT . assign ( { } , a , b ) ; const STR_UNDEFINED = 'undefined' ; export const hasWindow = ( ) => typeof window != STR_UNDEFINED ; export const hasDocument = ( ) => typeof document != STR_UNDEFINED ; export const hasRequestAnimationFrame = ( ) => hasWindow ( ) && typeof window [ 'requestAnimationFrame' ] != STR_UNDEFINED ;