nvp

nvpqs

NVP querystring parser.

Showing:

Popularity

Downloads/wk

23

GitHub Stars

8

Maintenance

Last Commit

5yrs ago

Contributors

5

Package

Dependencies

5

Size (min+gzip)

8.3KB

License

MIT

Type Definitions

Tree-Shakeable

No?

Categories

Readme

nvpqs

NVP parser. Like querystring, but for pairs where the name encodes primitive types, objects or arrays.

NPM Version Build Status Coverage Status Dependencies

Table of Contents

Installation

Install via NPM.

$ npm install nvpqs

Usage

parse(string, [del], [sep], [eq])

Deserialize a NVP query string to an object. Optionally override the default delimiter (.), separator (&) and assignment (=) characters.

Example

const Nvpqs = require('nvpqs');

Nvpqs.parse('a=b&c.d=e&f.0=g'); // { a: 'b', c: { d: 'e' }, f: ['g'] }

stringify(object, [del], [sep], [eq])

Serialize an object to a NVP query string. Optionally override the default delimiter (.), separator (&) and assignment (=) characters.

Example

const Nvpqs = require('nvpqs');

Nvpqs.stringify({ a: 'b', c: { d: 'e' }, f: ['g'] }); // 'a=b&c.d=e&f.0=g'

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100