> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stratumn.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Form action

> The most common type of action

Since no business related code is hardcoded in Stratumn, the form of the action is defined in the action's configuration using [react-jsonschema-form](https://rjsf-team.github.io/react-jsonschema-form/docs/),
a package that makes it easy to create dynamic forms with a JSON Schema, as well as handle dependencies between fields.

```ts theme={null}
const form: BetterFormDef = {
  schema: {
    title: 'A registration form',
    type: 'object',
    properties: {
      meal: {
        type: 'string',
        title: 'Meal'
      },
      comment: {
        type: 'string',
        title: 'Comment',
        format: 'draft'
      },
      required: ['meal']
    }
  },
  uiSchema: {
    'ui:order': ['meal', 'comment']
  }
};
```

### Prefill fields

<Info>TODO</Info>
