window-location-origin

Add support for browsers that don't natively support window.location.origin

npm install window-location-origin
1 downloads in the last week
4 downloads in the last month

Travis.ci NPM

window-location-origin.js

Add support for browsers that don't natively support window.location.origin

Example

window.location.origin
// #=> https://github.com/kylewelsby/window-location-origin

Install

Bower
bower install window-location-origin
NPM
npm install window-location-origin

Stackoverflow discussion: JavaScript/jQuery method to find base URL from a string

npm loves you