Socket
Socket
Sign inDemoInstall

querystring

Package Overview
Dependencies
0
Maintainers
2
Versions
5
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    querystring

Node's querystring module for all engines.


Version published
Weekly downloads
16M
increased by2.39%
Maintainers
2
Install size
10.0 kB
Created
Weekly downloads
 

Package description

What is querystring?

The querystring npm package is used for parsing and formatting URL query strings. It provides utilities for working with the query string of a URL, such as parsing a query string into an object, stringifying an object into a query string, and handling escape and unescape of URL query strings.

What are querystring's main functionalities?

Parsing a query string

This feature is used to parse a URL query string into an object where each key-value pair is represented as a property.

const querystring = require('querystring');
const parsed = querystring.parse('foo=bar&abc=xyz&abc=123');

Stringifying an object

This feature converts an object into a URL query string, with proper formatting and escaping.

const querystring = require('querystring');
const stringified = querystring.stringify({ foo: 'bar', baz: ['qux', 'quux'], corge: '' });

Escaping and unescaping

These functions are used to manually escape and unescape query string values.

const querystring = require('querystring');
const escaped = querystring.escape('foo@bar.com');
const unescaped = querystring.unescape('foo%40bar.com');

Other packages similar to querystring

Readme

Source

querystring

NPM gzip

Node's querystring module for all engines.

If you want to help with evolution of this package, please see https://github.com/Gozala/querystring/issues/20 PR's welcome!

🔧 Install

npm i querystring

📖 Documentation

Refer to Node's documentation for querystring.

📜 License

MIT © Gozala

Keywords

FAQs

Last updated on 15 Feb 2021

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc