const validation = function (
  item: string,
  min: number,
  max: number,
  regEx = /.*/,
) {
  if (
    item == undefined
    || item.length < min
    || item.length > max
    || !regEx.test(item)
  )
    return false
  else return true
}

export { validation }
