https://github.com/arikw/itm-to-wgs84-converter
A Zero dependency ITM to WGS84 coordinates converter
https://github.com/arikw/itm-to-wgs84-converter
coordinates-transformations datum datum-transformations ics israel itm wgs wgs84
Last synced: about 2 months ago
JSON representation
A Zero dependency ITM to WGS84 coordinates converter
- Host: GitHub
- URL: https://github.com/arikw/itm-to-wgs84-converter
- Owner: arikw
- License: other
- Created: 2022-08-14T09:14:06.000Z (over 2 years ago)
- Default Branch: master
- Last Pushed: 2022-08-23T20:53:09.000Z (over 2 years ago)
- Last Synced: 2025-02-01T11:42:26.117Z (3 months ago)
- Topics: coordinates-transformations, datum, datum-transformations, ics, israel, itm, wgs, wgs84
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/itm-to-wgs84-converter/
- Size: 31.3 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# ITM (Israeli Transverse Mercator) to WGS84 Converter
A Zero dependency ITM to WGS84 coordinates converter
# Installation
```sh
npm install itm-to-wgs84-converter
```# Usage
## Node
```js
// CommonJS
const ItmToWgs84Converter = require('itm-to-wgs84-converter');// ES Module
import ItmToWgs84Converter from 'itm-to-wgs84-converter';
```## Browser (CDN)
```js
// Classic// ES Module
import ItmToWgs84Converter from 'https://cdn.jsdelivr.net/gh/arikw/itm-to-wgs84-converter@1/dist/itm-to-wgs84-converter.browser.mjs';
```# Usage Examples
```js
// ITM to WGS84
{
const [ latitude, longitude ] = ItmToWgs84Converter.itm2wgs84(194140, 385060);
// output: [29.553103541791266, 34.943293095766144]
}// WGS84 to ITM
{
const [ east, north ] = ItmToWgs84Converter.wgs842itm(29.553103541791266, 34.943293095766144);
// output: [194140, 385060]
}// ICS to WGS84
{
const [ latitude, longitude ] = ItmToWgs84Converter.ics2wgs84(144140, 885060);
// output: [29.553036125579155, 34.943337203496604]
}// WGS84 to ICS
{
const [ east, north ] = ItmToWgs84Converter.wgs842ics(29.553036125579155, 34.943337203496604);
// output: [144140, 885060]
}```
# About
This package is based on the work of Joseph Gray who created the original C++ version and Michael Siton who created the C# version.