You will look at validating a form field when a value has changed and focus has been moved away with the handleChange function from the svelte-forms-lib.
handleChange