Validate User Input for Custom Flow Screen Components
Add validation to your custom screen components.
To use flow’s validation capabilities, create a function called validate() in your component’s JavaScript file. For errorMessage, enter your custom error message.
Arrow function expressions don’t work for validation in components with a target of lightning__FlowScreen. For example, this arrow function expression does not work for flow screen validation:
See Also