IGoToOptions

interface
Navigation & Scroll

Configuration object for the useGoTo() smooth-scroll service — controls container, duration, offset, easing and named easing patterns.

TypeScript

Définition

La définition TypeScript de l'interface telle que trouvée dans le code source d'origam. Cliquez sur l'icône de copie pour copier l'extrait.

typescript

API

Propriétés

Chaque propriété déclarée par cette interface, avec son type, son caractère optionnel et sa valeur par défaut.

container
requis
ComponentPublicInstance | HTMLElement | string
Scrollable container — a Vue component instance, a DOM element, or a CSS selector string. Defaults to window.
duration
requis
number
Scroll animation duration in milliseconds.
layout
requis
boolean
When true, the scroll target offset accounts for layout-registered sticky elements (appbar, footer).
offset
requis
number
Additional pixel offset applied on top of the target element position.
easing
requis
string | ((t: number) => number)
Easing function — a named key from `patterns` or an inline timing function that maps progress t ∈ [0,1] to an output value.
patterns
requis
IGoToOptionsPatterns
Named easing function registry — a record of name → timing function used to resolve the `easing` string.

Écosystème

Utilisé par

Composants et composables qui étendent ou consomment cette interface.

Usage

Exemples

Extraits de code prêts à coller utilisant cette interface.

Smooth-scrolling to a target with custom options

typescript