interface IObject { [ key ] : any ; } export const convertNumericToPixel = ( object , property ) => { if ( typeof object [ property ] === 'number' ) { object [ property ] = `${ object [ property ] }px` ; } } ;