import Tabs from '@theme/Tabs'; import TabItem from '@theme/TabItem'; import UppyCdnExample from '/src/components/UppyCdnExample'; # Form The `@uppy/form` plugin integrates with an existing HTML `
``` By default the code above will: 1. Extract meta data from the form `#my-form`. 2. Send it with the Uppy upload. 3. Those fields will then be added to Uppy meta data state (`uppy.state.meta`) and each file’s meta, and appended as (meta)data to the upload in an object with `[file input name attribute]` -> `[file input value]` key/values. 4. When Uppy completes upload/processing, it will add an `` with the stringified upload result object back to the form. :::note You can disable both of these features, see options below. ::: :::tip `@uppy/form` can also start Uppy upload automatically once the form is submitted, and even submit the form after the upload is complete. This is off by default. See [`triggerUploadOnSubmit`](#triggerUploadOnSubmit) and [`submitOnSuccess`](#submitOnSuccess) options below for details. ::: ## API ### Options #### `id` A unique identifier for this plugin (`string`, default: `'Form'`). #### `target` DOM element or CSS selector for the form element (`string` or `Element`, default: `null`). This is required for the plugin to work. #### `resultName` The `name` attribute for the `` where the result will be added (`string`, default: `uppyResult`). #### `getMetaFromForm` Configures whether to extract metadata from the form (`boolean`, default: `true`). When set to `true`, the Form plugin will extract all fields from a `