1const searchParams = new URLSearchParams(decodeURIComponent(location.search))2const params = Object.fromEntries(searchParams.entries())3 4console.log(params)