All Projects → Esri → Esri Leaflet Geocoder

Esri / Esri Leaflet Geocoder

Licence: apache-2.0
helpers for using the ArcGIS World Geocoding Service in Leaflet

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Esri Leaflet Geocoder

Esri Leaflet
A lightweight set of tools for working with ArcGIS services in Leaflet. 🚀
Stars: ✭ 1,356 (+726.83%)
Mutual labels:  web-development, arcgis, leaflet-plugins
Cedar
JavaScript Charts for ArcGIS
Stars: ✭ 230 (+40.24%)
Mutual labels:  web-development, arcgis
Arcgis Rest Js
compact, modular JavaScript wrappers for the ArcGIS REST API
Stars: ✭ 231 (+40.85%)
Mutual labels:  web-development, arcgis
Angular Esri Map
A collection of directives to help you use Esri maps and services in your Angular applications
Stars: ✭ 213 (+29.88%)
Mutual labels:  web-development, arcgis
Imagery-Apps
Example JavaScript source code for ArcGIS imagery apps (Landsat Explorer and Sentinel Explorer) that you can expand or customize.
Stars: ✭ 24 (-85.37%)
Mutual labels:  web-development, arcgis
esri-leaflet-vector
Display ArcGIS Online vector basemaps w/ Esri Leaflet
Stars: ✭ 39 (-76.22%)
Mutual labels:  web-development, leaflet-plugins
geoservices-js
Deprecated - please consider using @esri/arcgis-rest-js
Stars: ✭ 53 (-67.68%)
Mutual labels:  web-development, arcgis
Web
Kottans web course 🎓
Stars: ✭ 121 (-26.22%)
Mutual labels:  web-development
Responsively App
A modified web browser that helps in responsive web development. A web developer's must have dev-tool.
Stars: ✭ 14,425 (+8695.73%)
Mutual labels:  web-development
Graphav
A Graph Algorithms Visualizer built using React, Typescript and Styled Components.
Stars: ✭ 111 (-32.32%)
Mutual labels:  web-development
Maintenance Book
”SurviveJS — Maintenance” book
Stars: ✭ 105 (-35.98%)
Mutual labels:  web-development
Arcgis Webpack Plugin
Webpack plugin for the ArcGIS API for JavaScript
Stars: ✭ 125 (-23.78%)
Mutual labels:  web-development
Actix Web
Actix Web is a powerful, pragmatic, and extremely fast web framework for Rust.
Stars: ✭ 12,723 (+7657.93%)
Mutual labels:  web-development
Pi Temp
Web server using a Raspberry Pi and DHT22 sensor to graph the humidity and temperature in my apartment over time.
Stars: ✭ 114 (-30.49%)
Mutual labels:  web-development
Arcgis To Geojson Utils
Tools to convert ArcGIS JSON geometries to GeoJSON geometries and vice-versa.
Stars: ✭ 146 (-10.98%)
Mutual labels:  web-development
Pine
Functional HTML5 and XML library for the Scala platform
Stars: ✭ 108 (-34.15%)
Mutual labels:  web-development
R Bridge Install
Install the R ArcGIS Tools
Stars: ✭ 159 (-3.05%)
Mutual labels:  arcgis
Johnnydepp
A tiny dependency manager for modern browsers (992 bytes)
Stars: ✭ 143 (-12.8%)
Mutual labels:  web-development
Zaobao
每日时报,以前端技术体系为主要分享课题。根据:文章、工具、新闻、视频几大板块作为主要分类。
Stars: ✭ 1,961 (+1095.73%)
Mutual labels:  web-development
Dragon
dragon.js is a bookmarklet that lets you drag any element on a website using a mouse or touchscreen. The goal is to speed up in-browser design critiques and brainstorming new layout ideas.
Stars: ✭ 131 (-20.12%)
Mutual labels:  web-development

Esri Leaflet Geocoder

The Esri Leaflet Geocoder is a small series of API helpers and UI controls to interact with the ArcGIS Online geocoding services.

npm version build status apache licensed jsDelivr Hits

Example

Take a look at the live demo.

Example Image

<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8" />
    <title>Esri Leaflet Geocoder</title>
    <meta
      name="viewport"
      content="initial-scale=1,maximum-scale=1,user-scalable=no"
    />

    <!-- Load Leaflet from CDN-->
    <link rel="stylesheet" href="https://unpkg.com/leaflet/dist/leaflet.css" />
    <script src="https://unpkg.com/leaflet/dist/leaflet-src.js"></script>

    <!-- Load Esri Leaflet from CDN -->
    <script src="https://unpkg.com/esri-leaflet"></script>

    <!-- Esri Leaflet Geocoder -->
    <link
      rel="stylesheet"
      href="https://unpkg.com/esri-leaflet-geocoder/dist/esri-leaflet-geocoder.css"
    />
    <script src="https://unpkg.com/esri-leaflet-geocoder"></script>

    <!-- Make the map fill the entire page -->
    <style>
      #map {
        position: fixed;
        top: 0;
        bottom: 0;
        left: 0;
        right: 0;
      }
    </style>
  </head>

  <body>
    <div id="map"></div>
    <script>
      var map = L.map("map").setView([45.5165, -122.6764], 12);
      var tiles = L.esri.basemapLayer("Streets").addTo(map);

      // create the geocoding control and add it to the map
      var searchControl = L.esri.Geocoding.geosearch({
        providers: [
          L.esri.Geocoding.arcgisOnlineProvider({
            // API Key to be passed to the ArcGIS Online Geocoding Service
            apikey: 'YOUR_API_KEY'
          })
        ]
      }).addTo(map);

      // create an empty layer group to store the results and add it to the map
      var results = L.layerGroup().addTo(map);

      // listen for the results event and add every result to the map
      searchControl.on("results", function (data) {
        results.clearLayers();
        for (var i = data.results.length - 1; i >= 0; i--) {
          results.addLayer(L.marker(data.results[i].latlng));
        }
      });
    </script>
  </body>
</html>

API Reference

Controls

L.esri.Geocoding.geosearch

a control for auto-complete enabled search

Services

L.esri.Geocoding.geocodeService

A basic wrapper for ArcGIS Online geocoding services. Used internally by L.esri.Geocoding.geosearch.

Tasks

L.esri.Geocoding.geocode

An abstraction for submitting requests to turn addresses into locations.

L.esri.Geocoding.suggest

An abstraction for submitting requests for geocoding suggestions.

L.esri.Geocoding.reverseGeocode

An abstraction for submitting requests for address candidates associated with a particular location.

Development Instructions

  1. Fork and clone Esri Leaflet Geocoder
  2. cd into the esri-leaflet-geocoder folder and install the dependencies with npm install
  3. Run npm start from the command line. This will compile minified source in a brand new dist directory, launch a tiny webserver and begin watching the raw source for changes.
  4. The example at debug/sample.html should 'just work'
  5. Make your changes and create a pull request

Resources

Issues

Find a bug or want to request a new feature? Please let us know by submitting an issue.

Contributing

Esri welcomes contributions from anyone and everyone. Please see our guidelines for contributing.

Terms and Conditions

In order to make use of the ArcGIS Online World Geocoding Service in your web application:

  1. Please sign up for an ArcGIS for Developers account or purchase an ArcGIS Online Organizational Subscription.
  2. Ensure that Powered byEsri is displayed in the map attribution.

Cost

  1. User search for individual locations within web applications is defined by Esri as Geosearch and it is free. Credits are only consumed when you store results permanently.
  2. To store geocoding results, pass forStorage: true and a valid access token (see #207).
  3. You are not allowed to generate revenue while on a free ArcGIS Developer plan.
  4. If your application generates more than 1 million searches in a month, please contact us.

Licensing

Copyright © 2013-2018 Esri

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

A copy of the license is available in the repository's LICENSE file.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].