Skip to content

Instantly share code, notes, and snippets.

@JustAyush
Last active April 21, 2020 13:48
Show Gist options
  • Save JustAyush/64741f4ab6754000b61990efd1efc644 to your computer and use it in GitHub Desktop.
Save JustAyush/64741f4ab6754000b61990efd1efc644 to your computer and use it in GitHub Desktop.
let obj = {
bloodGroup:'A+',
coordinate: [12, 32]
}
let encodedBloodGroup = encodeURI(obj.bloodGroup);
let encodedLocation = encodeURI(obj.coordinate);
let page = 1;
let uri = `https://mozilla.org/?bloodGroup=${encodedBloodGroup}&coordinate=${encodedLocation}&page=${page}`;
console.log(uri);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment