Skip to main content

non_empty

Function non_empty 

Source
pub fn non_empty(message: impl Into<String>) -> impl Validator
Expand description

A validator that rejects empty or whitespace-only input with message.

A convenience for the most common rule; equivalent to a closure that trims and checks for emptiness.