Select your cookie preferences

We use essential cookies and similar tools that are necessary to provide our site and services. We use performance cookies to collect anonymous statistics, so we can understand how customers use our site and make improvements. Essential cookies cannot be deactivated, but you can choose “Customize” or “Decline” to decline performance cookies.

If you agree, AWS and approved third parties will also use cookies to provide useful site features, remember your preferences, and display relevant content, including relevant advertising. To accept or decline all non-essential cookies, choose “Accept” or “Decline.” To make more detailed choices, choose “Customize.”

Name:
interface
Value:
Amplify has re-imagined the way frontend developers build fullstack applications. Develop and deploy without the hassle.

Page updated Apr 29, 2024

Extend input element in code

Amplify Studio Forms are all based on top of the Amplify UI library. The generated form provides a mechanism to override properties for each individual input component.

Dynamically modify specific input properties

Use the overrides property to select the input component you want to override and then pass in the props that you'd like to change. For example, we want to dynamically toggle the descriptive text of a particular form element:

function ProductFormContainer({ productType }) {
return (
<div className="App">
<ProductForm
overrides={{
name: {
descriptiveText: `Enter ${productType} name`
}
}}
/>
</div>
);
}

Note: We do not recommend overriding properties that are already set by the generated form. This could lead to unexpected behavior during runtime. Verify the set properties by navigating to the component in the src/ui-components/<your-form-component>.jsx file.