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

# Settings Configuration

> Build user-facing settings forms for your LinkApp

The `settings` section of `linkapp.config.ts` defines the form people fill out when they add your LinkApp. Whatever they enter comes back to your layouts as strongly typed props.

## Minimal Example

```ts linkapp.config.ts theme={"system"}
export default {
  settings: {
    title: "Weather LinkApp",
    overview: {
      title: "Weather LinkApp",
      description: "Show live weather for a chosen city.",
    },
    elements: [
      {
        id: "location",
        inputType: "text",
        label: "City",
        defaultValue: "San Francisco",
        validation: { required: true },
      },
    ],
  },
};
```

### Flow

1. You define elements in `linkapp.config.ts`.
2. Users complete the generated form inside Linktree.
3. Layout components receive the answers via `AppProps`.

```tsx app/expanded.tsx theme={"system"}
type Settings = {
  location: string;
};

export default function ClassicLayout({ location }: AppProps<Settings>) {
  return <div>Weather for {location}</div>;
}
```

## Elements in a Nutshell

Each object in `settings.elements` becomes a form field and a prop. Focus on these keys:

* `id` – unique prop name (use camelCase).
* `inputType` – field type (`text`, `switch`, `select`, etc.).
* `label` / `title` – copy shown in the form.
* `defaultValue` – starter value.
* `validation` – optional rules.

For the complete element catalog, head to `/essentials/settings-reference`.

## Helpful Options

* `title` – heading shown above the form.
* `overview` – short description block at the top.
* `uses_url` – require the built-in `linkUrl` field.
* `settings_tab_title` – rename the settings tab text.
* `setup_instructions` – markdown-friendly setup tips for complex flows.

You rarely need to set `has_settings`; it's inferred when `elements` is present.

## Tips

* Pick descriptive IDs because they become prop names.
* Give defaults so the preview works immediately.
* Keep descriptions short and actionable.

Ready for more input types? Read `/essentials/settings-reference` when you need the details.
