The Wayback Machine - https://web.archive.org/web/20200412235704/https://github.com/Richienb/iplocation
Skip to content
Get ip location information.
TypeScript
Branch: master
Clone or download

Latest commit

Richienb Fix leading whitespace
Signed-off-by: Richie Bendall <richiebendall@gmail.com>
Latest commit b94c090 Apr 8, 2020

Files

Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
source Update examples Apr 3, 2020
.editorconfig Fix leading whitespace Apr 8, 2020
.gitattributes Refactor code Apr 3, 2020
.gitignore Refactor code Apr 3, 2020
.npmrc Refactor code Apr 3, 2020
.travis.yml
LICENSE
README.md Add cli to related Apr 4, 2020
package.json
test.ts Properly export default and fix lint Apr 3, 2020
tsconfig.json Refactor code Apr 3, 2020

README.md

iplocation Travis CI Build Status

Get ip location information.

NPM Badge

Install

npm install iplocation

Usage

const ipLocation = require("ip-location");

(async () => {
	await ipLocation("172.217.167.78");
	//=> { latitude: -33.8591, longitude: 151.2002, region: { name: "New South Wales" ... } ... }
})();

API

ipLocation(ip)

ip

Type: string

The ipv4 address to get the information for.

Related

You can’t perform that action at this time.