Check if ip address or dns name belong to your local machine
A tiny script that return the promise, if it belongs to your local machine.
check-localhost is on npm, so installing it is as easy as doing:
$ npm install --save check-localhost
require('check-localhost') in your script. After that you can call it like this (all options are optional):
var checkLocalHost = ;
IE9 and up