Tweakr
    Preparing search index...

    Function setQueryParam

    • Sets or updates a query parameter in the current URL without reloading the page.

      Parameters

      • key: string

        The name of the query parameter.

      • value: string

        The value to set for the query parameter.

      Returns void

      // URL: https://example.com
      setQueryParam("page", "2");
      // URL becomes: https://example.com?page=2

      1.1.0