node-parse-url
v5.1.0
Published
Take a URL string, and return an object. extend from native url module
Downloads
134
Readme
node-parse-url
Take a URL string, and return an object. Extend from native url module
Installation
Global
npm install node-parse-url
Usage
var parseUrl = require('node-parse-url');
var url = parseUrl('https://github.com/aredo');
console.log(url);
// output
// {
// protocol: 'https:',
// host: 'github',
// port: null,
// hostname: 'github.com',
// path: '/aredo',
// subdomain: null,
// tld: 'com',
// domain: 'github.com'
// }
License
(The MIT License)