New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

mdimapgeocoder

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mdimapgeocoder

mdimapgeocoder ===============

  • 0.1.6
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

MDiMapGeocoder

A library to use Maryland's cascading geocoder in Node.js and the browser

##Installation

###Node.js

  • Run npm install mdimapgeocoder
var MDiMapGeocoder = require('mdimapgeocoder')

###Browser

  • Download build/MDiMapGeocoder.min.js
<script src="MDiMapGeocoder.min.js"></script>

##Usage

MDiMapGeocoder.search(address, options?, callback)
  • address - string containing full address or object containing Street, City, State, ZIP
  • options - optional object containing search options (see below)
  • callback - function(error, response) {}

Example


//Single Line
MDiMapGeocoder.search('1101 Camden Ave, Salisbury MD 21801', function(err, res){
  // example response
  res.candidates[0] = 
    {
      "address" : "1101 CAMDEN AVE, SALISBURY, MD, 21801",
      "location" : {
        "x" : -75.609389996999937,
        "y" : 38.342533962000061
      },
      "score" : 100,
      "attributes" : {}
    }
})

//Address Fields
MDiMapGeocoder.search({
  Street: '1101 Camden Ave',
  City: 'Salisbury',
  State: 'MD',
  ZIP: '21801'
}, function(err, res){
  
})

Options

  • wkid - Specify WKID to return. Default 4326
MDiMapGeocoder.search('1101 Camden Ave, Salisbury MD 21801', {wkid: 26985}, function(err, response) {
  // response.location = {"x":521564.8398928333,"y":75950.13939312194}
})
  • outFields- The list of fields to be included in the returned results.
MDiMapGeocoder.search('1101 Camden Ave, Salisbury MD 21801', {outFields: ['ZIP', 'City']}, function(err, response) {
  // response.attributes = { ZIP: '21801', City: 'SALISBURY' } }
})

FAQs

Package last updated on 14 Oct 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc