import path from 'path' ; param base param filePath returns export const ensureAbsolutePath = ( base , filePath ) : string => path . isAbsolute ( filePath ) ? filePath : path . resolve ( base , filePath ) ;