A library for parsing, validating and stringifying geographical coordinates of various formats.
A library for parsing, validating and stringifying geographical coordinates of various formats.
- π€ Parses possible coordinates of different formats if the received input is ambigious. By default the following formats are recognized:
- Decimal Degrees (Lat/Lon)
- Degrees Minutes
- Degrees Minutes Seconds
- Open Location Code
- OpenStreetMap URL
- Google Maps URL
- βοΈ Uses sensible defaults i.e. for parsing confusable unicode characters.
- πΊοΈ Made to integrate easily with mapping libraries like Leaflet.js and Mapbox GL JS.
- π‘ Written in TypeScript for a fully typed API.
- ποΈ Provides utilities and for adding custom coordinate formats.
bash
npm i coordinate-formats
`Documentation
See the official docsDevelopment
In order to start with the development, clone the repository and run:Install npm dependencies:
`bash
npm install
`Run the development environment:
`bash
npm start
``