{"version":"1.0","type":"rich","title":"get Url Parameters with vanilla js","description":"This example demonstrates how to retrieve URL parameters using vanilla JavaScript, specifically extracting an `id` value from the query string. It shows two functions: `getQueryParams()`, which parses the search portion of the URL into a key-value object by splitting on `&` and `=`, and `getUrlId()`, which returns the `id` parameter from that object. The code relies on the browser’s `window.location.search` API and basic string manipulation, with no external libraries. It highlights a lightweight, dependency-free approach to handling query parameters for tasks like loading specific content based on a URL identifier.","provider_name":"VizHub AI Studio","provider_url":"https://next.vizhub.com","html":"<iframe src=\"https://next.vizhub.com/viz/gist-b5908a5027cfc420d3619fb3f395bb8b?mode=embed\" width=\"960\" height=\"500\" scrolling=\"no\" frameborder=\"1\"></iframe>","width":960,"height":500,"cache_age":3600}