Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/cities/mod.ts>CityService

🦕 module provides information about cities on earth + mars
Latest
class CityService
import { CityService } from "https://deno.land/x/cities@v1.2.0/mod.ts";

Static Properties

private
minimumPopulation: number

Static Methods

getCitiesByCountryCode(
countryCode: string,
minimumPopulation?: number,
maximumPopulation?: number,
): ICityInfo[]
getCitiesByPopulation(minimumPopulation: number, maximumPopulation?: number): ICityInfo[]
getCityInfo(countryCode: string, cityName: string): ICityInfo
getClosestCity(
latitude: number,
longitude: number,
minimumPopulation?: number,
maximumPopulation?: number,
): ICityInfo