get-location-origin
v1.0.0 window location origin protocol hostname port url browser
get-location-origin
Get the window.location.origin string - even if not supported by the browser
- This is not a polyfill
- Does not modify the
window.location
object
Install
npm install --save get-location-origin
Usage
var origin = require('get-location-origin');
console.log(origin);
// => "http://localhost:3000"
npm i get-location-origin
Metadata
- MIT
- Whatever
- Noel Delgado
- released 7/19/2015