FormProps
interface FormProps extends [React.FormHTMLAttributes]<HTMLFormElement> {
action?: string;
method?: FormMethod;
onSubmit?: React.FormEventHandler<HTMLFormElement>;
preventScrollReset?: boolean;
relative?: RelativeRoutingType;
reloadDocument?: boolean;
replace?: boolean;
}§Properties
§
method?: FormMethod
[src]The HTTP verb to use when the form is submit. Supports "get", "post", "put", "delete", "patch".
§
onSubmit?: React.FormEventHandler<HTMLFormElement>
[src]A function to call when the form is submitted. If you call
event.preventDefault()
then this form will not do anything.
§
preventScrollReset?: boolean
[src]Prevent the scroll position from resetting to the top of the viewport on completion of the navigation when using the component
§
relative?: RelativeRoutingType
[src]Determines whether the form action is relative to the route hierarchy or the pathname. Use this if you want to opt out of navigating the route hierarchy and want to instead route based on /-delimited URL segments