Function copySearchParams

Copies the search params from one url to another

  • Parameters

    • targetUrl: string

      the url to copy the search params to

    • sourceUrl: string

      the url container the search params we want to copy

    Returns string

    the url with the search params copied