code: function wrap (rule) {
    return ($) => {
      let value = rule($)
      if (typeof value !== 'string') return
  
      // make sure it's a url
      value = value.trim()
      if (!isUrl(value)) return
  
      return value
    }
  }
docs: Wrap a rule with validation and formatting logic.
  
  @param {Function} rule
  @return {Function} wrapped