Primitives / foldkit-primitives/dom

Autofocus

const · packages/primitives/src/dom/autofocus.ts:14

const Autofocus: Mount.MountDefinitionNoArgs<
  'Autofocus',
  { readonly _tag: 'Focused' }
>

Autofocus as a Mount: focuses the element on insert, then emits Focused. The message means focus was requested — a non-focusable element or a hidden tab may decline, and the browser does not report that. Plain focus(), no scroll options: scroll behavior stays the application's choice.

In the guides