Is it a UK postcode?
See also
Other code detectors:
is_ca_postal_code(),
is_country_code(),
is_http_status(),
is_roman(),
is_unix_time(),
is_us_state(),
is_version(),
is_zip_code()
Examples
is_uk_postcode(c("SW1A 1AA", "IV40 8AJ", "12345", NA))
#> [1] TRUE TRUE FALSE NA