normalize-domain
v0.0.124
Published
Given a url, returns the fully qualified domain name.
Downloads
10
Readme
normalize-domain
Given a url, returns the fully qualified domain name.
Installation
npm i normalize-domain --save
Usage
const normalize = require('normalize-domain')
normalize('https://www.google.com')
// => google.com
normalize('www.google.com')
// => google.com
normalize('https://firebase.google.com/')
// => firebase.google.com