1.0.0 • Published 6 years ago

lazyport v1.0.0

Weekly downloads
1
License
MIT
Repository
github
Last release
6 years ago

Lazyport

Installation

$ npm add lazyport

Usage

Find nearby airports

import { Lazyport } from "lazyport"

const nearby = new Lazyport().nearby(latitude, longitude, radius);

// Results
console.dir([{
  name: string;
	city: string;
	country: string;
	iata: string;
	icao: string;
	latitude: number;
	longitude: number;
	altitude: number;
	dst: string;
	tz: string;
	distance: number;
}])

Search airports

import { Lazyport } from "lazyport"

const results = new Lazyport().search("kmi");

// Results
console.dir([{
  name: string;
	city: string;
	country: string;
	iata: string;
	icao: string;
	latitude: number;
	longitude: number;
	altitude: number;
	dst: string;
	tz: string;
	distance: number;
}])

API

Description
nearby(latitude, longitude, radius)Find nearby airports based on input coordinates and radius (defaults to 50km)
search(query)Search airports by name, city, country, iata, icao