Promissa saysThe location object reads and changes the current URL and its parts.
location.href is the full URL; pathname, search (query string), hash, hostname, and protocol break it down. Assigning location.href = url (or location.assign) navigates; location.reload() refreshes; location.replace navigates without a history entry. Parse queries with new URLSearchParams(location.search).
Power-ups you unlock
location.href + pathname/search/hash/hostname
Assigning href navigates the page
reload() refreshes; replace() skips history
URLSearchParams parses the query string
Race Condition Rex attacks — common mistakes
String-parsing the query instead of URLSearchParams
Confusing assign (history entry) with replace (none)
Forgetting hash changes don’t reload
Boss battleRead a query parameter with URLSearchParams and display it.