egnha / valaddin

Functional input validation to make R functions more readable and robust
Other
33 stars 1 forks source link

Update README to simplified API #53

Closed egnha closed 7 years ago

egnha commented 7 years ago

Substantial simplification in new API: instead of

firmly(foo, partial(rlang::is_double, n = 1) ~ vld(x, y, z))

it is now possible to write

firmly(foo, rlang::is_double(n = 1, x, y, z))

or even shorter (and with a more informative error message)

firmly(foo, vld_double(n = 1, x, y, z))