Validate values against an allowed set
check_enum.RdChecks that every element of x is found in valid. NULL
passes silently. Aborts with an informative error if invalid
values are found.
Usage
check_enum(x, valid, arg = rlang::caller_arg(x))Examples
check_enum("active", c("active", "inactive", "pending"))