required
Checks that the value is present: not missing, not null and not an empty string. Note that 0 and false are valid values.
Error code: REQUIRED
rules
input
Invaliderrors
{
"last_name": "REQUIRED"
}All other rules except not_empty and not_empty_list skip empty values, so combine them with required for mandatory fields:
js
{ first_name: ['required', { min_length: 2 }] }