ScrollRestorationProps: ScriptsProps & {
    getKey?: GetScrollRestorationKeyFunction;
    storageKey?: string;
}

Type declaration

  • OptionalgetKey?: GetScrollRestorationKeyFunction

    Defines the key used to restore scroll positions.

    <ScrollRestoration
    getKey={(location, matches) => {
    // default behavior
    return location.key
    }}
    />
  • OptionalstorageKey?: string