Public
Script
Readme

qs

QS is a pretty old module that you probably shouldn't use but it's still pretty heavily used.

In the very very early days there wasn't a built-in way in JavaScript to parse querystrings. So QS was born. But then, Node.js added a querystring module built-in. Then, JavaScript introduced URLSearchParams, which you should use whenever you want to parse or generate query strings.

1
2
3
4
export let qsExample = (async () => {
const qs = await import("npm:qs");
return qs.parse("?hi=there");
})();
Val Town is a social website to write and deploy JavaScript.
Build APIs and schedule functions from your browser.
Comments
Nobody has commented on this val yet: be the first!
October 23, 2023