google-maps-drawing-measurements
v1.0.39
Published
Draw poly and measure its lengths and area on Google Map
Readme
google-maps-drawing-measurements
Draw poly and measure its lengths and area on Google Map.
Usage
# install google-maps-drawing-measurements
npm install google-maps-drawing-measurements format-unit
# install peerDependecy format-unit// import lib
import * as GMDM from 'google-maps-drawing-measurements'
// set map
GMDM.setMap(map)
// start measuring
GMDM.start()
// stop measuring
GMDM.stop()
// start measuring from existing shape
GMDM.start([
[-116.71335014686588, 47.95272425175882],
[-116.71021732673648, 47.952810478513214],
[-116.71030315742496, 47.95384518834307],
])}
// track changes
GMDM.on('coordinates', console.log)Development
Client side ESM module bundled as ESM module with rollup.
