vapor-chamber API reference - v1.16.0
    Preparing search index...

    Type Alias QueryParamHandle<T>

    QueryParamHandle: Ref<T> & {
        push: (next: T) => void;
        replace: (next: T) => void;
        clear: () => void;
    }

    A real Vue Ref whose backing store is the URL, plus explicit history controls.

    Being an actual ref matters: refs returned from setup() are AUTO-UNWRAPPED in templates, so {{ page }} works and .value is script-only — exactly like useRoute(), useRouteData() and every sibling composable. A lookalike object with a value accessor does NOT unwrap, which made this the one composable whose templates needed .value.

    Type Parameters

    • T

    Type Declaration

    • push: (next: T) => void

      Write with an explicit pushState (back returns to the old value).

    • replace: (next: T) => void

      Write with an explicit replaceState (no history entry).

    • clear: () => void

      Remove the key from the URL (reads fall back to the declared default).