Giter Club home page Giter Club logo

esri-leaflet-doc's Introduction

The official Esri Leaflet documentation has moved to developers.arcgis.com/esri-leaflet, and this repository is archived. If you have any suggestions or contributions for the documentation going forward, please log an issue in the Esri Leaflet repository (select "Documentation").

Esri Leaflet Documentation Site

Instructions

  1. Clone this repository.
  2. npm install -g grunt-cli
  3. npm install
  4. Create a new file, data/secret.json to include an API Key:
    {
      "api_key": "YOUR API KEY HERE"
    }
    
  5. npm start

In order to update the version of Leaflet, Esri Leaflet or any other plugin displayed in the documentation site:

  1. Find and update the appropriate library version listed in package.json devDependency.
  2. Rerun npm install.
  3. Run npm run integrity (to generate a corresponding Subresource Integrity hash).
  4. Run npm start to confirm locally that this achieved the desired effect.
  5. Send a Pull Request!

Development Tips

Testing/Linting

Before committing, run npm test, which will run ESLint (enforcing the Semistandard style) on all our sample code to ensure the samples are consistently formatted.

File changes will be watched and also linted with ESLint if you have run npm start prior to editing the samples.

VS Code

If you're using VS Code and the ESLint Extension, you can create a new file at .vscode/settings.json with the following contents to enable live linting on the HBS files:

{
  "eslint.validate": [
    "javascript",
    "javascriptreact",
    "handlebars"
  ]
}

Local Esri-Leaflet

If you're working on changes to esri-leaflet locally and want to see those changes within the context of the documentation site:

  1. Run npm start in the esri-leaflet project. This will host the built esri-leaflet file at http://localhost:5000/dist/esri-leaflet-debug.js or similar.
  2. In this repository, in \data\devSiteData.json, set the localSource property to true and set the localSourceUrl property to the full url of your esri-leaflet-debug.js file if it's not the same as above.
  3. Run npm start in this project, and the documentation site will be hosted but load the esri-leaflet library locally instead of the CDN version.

Issues

Find a typo or other problem on the website? Please let us know by submitting an issue.

Contributing

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

Licensing

Copyright © 2015-2019 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.

esri-leaflet-doc's People

Contributors

bazlo avatar brunocaimar avatar cgalvarino avatar dangowans avatar datdoan avatar dependabot[bot] avatar eeeschwartz avatar gavinr avatar gavinr-maps avatar jgravois avatar jwasilgeo avatar lillie-bahrami avatar miketschudi avatar mmaclach avatar nickpeihl avatar npmcdn-to-unpkg-bot avatar omnisis avatar patrickarlt avatar pmacmaps avatar rowanwins avatar tomwayson avatar tormi avatar tyleralves avatar znseaman avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

esri-leaflet-doc's Issues

Document what is available at 1.x.x vs. 2.x.x

Can there be documentation as to what features are available at 2.x.x and 1.x.x?

I was experimenting with L.esri.find and got Uncaught TypeError: L.esri.find is not a function when using the 1.x.x version.

It seemed to work at the 2.x.x version. It would be nice to know ahead of time what works with what version.

clarify how to specify a custom pane for a point layer

Leaflet expects custom panes to be passed through as an option within pointToLayer()

map.createPane('custom');

L.esri.featureLayer({
  url: 'https://services.arcgis.com/rOo16HdIMeOBI4Mb/...',
  pointToLayer: function (geojson, latlng) {
    return L.marker(latlng, { pane: 'custom' };
  }
}).addTo(map);

it would be good for us to add another layer of points to the sample below and make explicit mention of this in the API reference.
http://esri.github.io/esri-leaflet/examples/layer-ordering.html

document L.esri.featureLayer's new 'ignoreRenderer` constructor option

once the esri-leaflet-renderers 2.0.2 is live, we'll need to document the Esri/esri-leaflet-renderers#111 change on the website.

ignoreRenderer, boolean, defaults to false

it might make more sense to just mention the new constructor option in the existing L.esri.featureLayer API reference page for L.esri.featureLayer noting that the plugin is required to make use than it would to create a seperate page purely for the plugin.

either way, it'd be good to mention the new feature in the esri-leaflet-renderers README as well.

@kneemer

query orderBy documentation clarification

The documentation could clarify the correct strings for ascending or descending in the second parameter of the orderBy method.

For example, when I am querying a featureLayer hosted on ArcServer, I can use "descending" and it works. But if I am querying a featureLayer hosted on AGOL, I found that "desc" works.

descending

Identifying Features Demo has no data displayed (Dead URL??)

Troubles on Identifying Feature Demo
It appears the url for the map service (https://tmservices1.esri.com/arcgis/rest/services/LiveFeeds/Earthquakes/MapServer) is no longer available. I went to the Service link and did not see Earthquakes listed. When I checked the "USGS_Seismic_Data" service on that server it shows that the service is scheduled to be retired at the end of the year and is being replaced with an ArcGIS Online service.
I would have tried to come up with a PR but didn't know what service you might want to use for this example.

Examples for 1.x Versions

I am still developing applications using the 0.7.x version of Leaflet and 1.x.x version of the Esri plugins. It appears that the API reference and examples are for 2.x.x versions of the plugins.

Is there a way that the examples and reference can be available for older versions of the plugins?

misc geosearch typos in doc

  • get rid of new keyword in geosearch samples
  • get rid of extra maxResults items in individual geosearch providers in API ref
  • mention that 15 is the max number of suggestions typically supported
  • bufferRadius**,**
  • reverse())

Typo in L.esri.TiledMapLayer

Third paragraph says:

Is you have Feature Services published in ArcGIS Online you can create a static set of tiles using your Feature Service. You can find details about that process in the ArcGIS Online Help

Probably intended:

If you have Feature Services published in ArcGIS Online you can create a static set of tiles using your Feature Service. You can find details about that process in the ArcGIS Online Help

Some examples are not working on http connections

Some examples are not working on http connections due to the service that they are using are not accepting http connections anymore.

Some of the examples that are not working: Simple FeatureLayer, Custom popups, Querying features, etc.

I'll try to send a pull request to fix it soon.

bad_request_on_leaflet_example

add 'USATopo' to API reference

we're looking for help from someone to add new information to the API reference to mention the new basemap key that @mattficke added in Esri/esri-leaflet#758

  1. check out our 'getting started'
  2. the source code for L.esri.basemapLayer can be found here
  3. commit your changes and submit a pull request to compare your own branch with upcoming

note: we'll use upcoming as the branch in this repository to store the documentation change because the new basemap won't be available to end users until after we tag our next release of Esri Leaflet.

i'm happy to answer questions if any of this is unclear.

fix final code snippet in feature layer tutorial

sorry @pmacMaps, i didn't see your commit comment until after i merged the new tutorial.

the signature of bindPopup changed between esri leaflet 1.x and 2.x. if you set a breakpoint and inspect the variable passed in bindPopup()s callback function in 1.x you can see that it refers to an individual GeoJSON feature, not a generic mouse event.

screenshot 2016-08-26 14 25 44

because of this, you'll need to tweak the code slightly to update the reference to individual attribute fields. let me know if you need more of a clue than that.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.