Answers for "window.history.pushstate typescript"

1

window.history.pushstate typescript

const url = new URL(window.location.href);
url.searchParams.set("key", "value");
const href = url.toString();
window.history.pushState({}, '', href);
Posted by: Guest on June-06-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language