Skip to content

Node module that parses a path to an object. Each section of the pathname is the index and merged with the querystring.

License

Notifications You must be signed in to change notification settings

MiniGod/path-obj

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

path-obj

Parses a path to an object. Each section of the pathname is indexed and merged with the querystring.

Example

const pathObj = require('path-obj')

pathObj('/a/b/c/?d=e&f=g')

// result:
// {
//   0: 'a',
//   1: 'b',
//   2: 'c',
//   d: 'e',
//   f: 'g'
// }

About

Node module that parses a path to an object. Each section of the pathname is the index and merged with the querystring.

Resources

License

Stars

Watchers

Forks

Packages

No packages published