# Introduction

> Forms for React and Solid, with the form logic in one small core.

Source: https://forms.lunarhue.dev/solid/introduction

The core holds values, arrays, errors and submit state, and knows nothing about either framework. The adapter, `@lunarhue/forms-react` or `@lunarhue/forms-solid`, connects it to your components. A Vue adapter is planned.

Validation is built in. Undo, input masks, schema libraries and the rest are plugins, all imported from one `plugins` entry. Your bundle carries only the ones you import.

Field names are typed. The form's value type comes from its starting values,
and every `name` you write is checked against it:

```tsx
const signUp = createForms().define({
  defaultValues: { name: "", email: "" },
  onSubmit: (value) => save(value),
});

function SignUpForm() {
  const form = createForm(signUp);
  return (
    <form.Form>
      {(formProps) => (
        <form {...formProps}>
          <form.Field name="name">{(field) => <input {...inputProps(field)} />}</form.Field>
          {/* Type error: "emial" is not a field of signUp. */}
          <form.Field name="emial">{(field) => <input {...inputProps(field)} />}</form.Field>
        </form>
      )}
    </form.Form>
  );
}
```

## Where to go next

- [Install](https://forms.lunarhue.dev/solid/install.md) the adapter.
- Build [your first form](https://forms.lunarhue.dev/solid/basics/first-form.md). The Basics pages after it use no plugins.
- Make [reusable field components](https://forms.lunarhue.dev/solid/composition/field-components.md) once the forms repeat themselves.
- Add [plugins](https://forms.lunarhue.dev/solid/plugins/using-plugins.md) for dirty tracking, undo, masks and the rest.
