- Notifications
You must be signed in to change notification settings - Fork6
Open
Description
When using aFormSelect, its name field is type checked, but its options are not.
typeFormData={enum:"option1"|"option2"|"option3";};constform=useForm({enum:"option1"}asFormData);// ...<FormSelectform={form}name="enum"><optionvalue="option1">Option 1</option><optionvalue="option2">Option 2</option><optionvalue="option3">Option 3</option>{/* Next line does not show error, but option4 is invalid! */}<optionvalue="option4">Option 4</option></FormSelect>;
This should be possible to typecheck by only accepting children of a specific type inFormSelect.