1.3.4 • Published 3 years ago
wmk-netlify-form v1.3.4
wmk-netlify-form
Used to aid creating Netlify forms utilizing the component.
There are four main props, two of which are configuration objects:
export interface NetlifyFormProps {
title?: string | React.FunctionComponent<any>; // A form title or Compononet in place of a form title
/*
An array of input field properties.
You can use either a pre-configured component or a custom component
*/
fields: {
as?: NetlifyFormAs; // An optional pre-configured input component
props?: { [key: string]: any }; // Props that will be sent to the component
Component?: React.FunctionComponent<{ [key: string]: any } | {}>; // An optional custom component
}[];
/* Configure the form itself */
config: {
name: string; // A unique name that will be used in the Netlify forms backend
thankYou?: React.ReactNode; // A thank you message (string) or thank you component
thankYouPage?: string; // An URL or path to a thank you page.
consoleMessage?: boolean; // Show submitted form data for debugging
submit?: string; // Change the text on the submit button
postUrl?: string; // A valid local Netlify URL
keepDom?: boolean; // Retain or destroy element in DOM after suubmission
encType?: "multipart/form-data" | "application/x-www-form-urlencoded"; // Only change to multipart if submitting a file
testing?: boolean; // Set to true to test form without submitting
};
onSubmit?: (data: { [key: string]: string }) => void; // Run code with access to submitted data on sucessful submit
}
1.3.4
3 years ago
1.3.3
3 years ago
1.3.2
3 years ago
1.3.1
3 years ago
1.3.0
3 years ago
1.2.0
3 years ago
1.1.3
3 years ago
1.1.2
3 years ago
1.1.1
3 years ago
1.1.0
3 years ago
1.0.15
3 years ago
1.0.14
3 years ago
1.0.13
3 years ago
1.0.12
3 years ago
1.0.11
3 years ago
1.0.10
3 years ago
1.0.9
3 years ago
1.0.8
3 years ago
1.0.7
3 years ago
1.0.6
3 years ago
1.0.5
3 years ago
1.0.4
3 years ago
1.0.3
3 years ago
1.0.2
3 years ago
1.0.1
3 years ago
1.0.0
3 years ago