# Creating form

React Advanced form treats any form as a composition of fields. Therefore, creating a form is a trivial procedure of rendering field components as the form's children.

{% hint style="warning" %}
Make sure you have [field components defined](https://redd.gitbook.io/react-advanced-form/getting-started/creating-fields) before proceeding with this step.
{% endhint %}

## Example

```jsx
import React from 'react'
import { Form } from 'react-advanced-form'

/* Fields */
import { Input, Checkbox } from '../fields'

export default class ExampleForm extends React.Component {
  render() {
    return (
      <Form>
        <Input
          name="userEmail"
          required />
        <Input
          name="userPassword"
          type="password"
          required />
        <Checkbox
          name="termsAndConditions" />
      </Form>
    )
  }
}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://redd.gitbook.io/react-advanced-form/getting-started/creating-form.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
