fix(types): improve documentation

This commit is contained in:
Divlo
2022-08-26 23:05:38 +02:00
parent c979bab553
commit 50d724eb6a
3 changed files with 28 additions and 9 deletions

View File

@ -4,6 +4,10 @@ export interface FormDataObject {
[key: string]: FormDataEntryValue
}
/**
* @param formData Object where the keys are the name of your inputs and the current value.
* @param formElement The HTML form element in the DOM.
*/
export type HandleForm = (
formData: FormDataObject,
formElement: HTMLFormElement