title: Change url and set querystring together
body: <p>I’ve a question, I wanna change url and set query also in new url I use queryString library , i know for changing url I can do this : </p>
  
  <pre><code>window.location.href = “example.com” 
  </code></pre>
  
  <p>But I also set a query like this : </p>
  
  <pre><code>const queryString = require(‘query-string’)
  
  var parsed={};
  parsed.url = window.location.toString();
  const stringified = queryString.stringify(parsed);
  </code></pre>
  
  <p>then I wrote:</p>
  
  <pre><code>window.location.href = “example.com/“ + stringified
  </code></pre>
  
  <p>But it doesn’t work, would you help me? </p>