• Node.js Video Tutorials

Node.js - QueryString Module



QueryString module of Node.js provides utilities for parsing and formatting URL query strings. The QueryString module is much better in terms of performance when compared to URLSearchParams, but this is not a standardized API. The module also provides methods to serialize JavaScript objects into query strings, as well as methods for encoding and decoding URI components

List of Methods

Following is a list of methods available in the QueryString Module −

Sr.No Function & Description
1

escape()

Used to return a percent-encoded query string from a normal string.

2

parse()

Used to parse a URL query string into a collection of key and value pairs.

3

stringify()

Used to produce a URL query string from a given object.

4

unescape()

Used to decode the URL percent-encoded characters in the query string.

Advertisements