Skip to content

timemrah/addRemoveUrlQuery

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 

Repository files navigation

addRemoveUrlQuery

I practically wrote the following function to process the url parameters and get the final status as a url query string.

For example, when I click a button, I want the category value to be added and number of page value to be deleted from url query.

let button = document.getElementById('changeCategory');
button.addEventListener('click', function (e) {

    window.location = addRemoveUrlQuery({'category':'cars'}, ['page_num']);

});

I think it was very useful!

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published