constForm:Component=()=>{const form_name ="custom_validation";asyncfunctioncorrectName(){const values =getValues(form_name);if(values){if(values.myname !="hey i am solidjs"){returnfalse;}returntrue;}returnfalse;}constfields: IField[]=[{type:"input",name:"myname",attributes:{type:"text",id:"myname",label:"Name",placeholder:"Tap i am solidjs",// optional},rules:["required",{name:"correctName",fnc: correctName }],messages:{correctName:"Should say: hey i am solidjs",},preprocess:(field, fields, values)=>{return field;},},];return(<Formly
form_name={form_name}
fields={fields}
onSubmit={onSubmit}/>);};exportdefault Form;