{"id":28533712,"url":"https://github.com/esri/esri-leaflet-static-basemap-tile","last_synced_at":"2026-02-25T20:01:01.160Z","repository":{"id":257810037,"uuid":"845218287","full_name":"Esri/esri-leaflet-static-basemap-tile","owner":"Esri","description":"Display ArcGIS static basemap tiles w/ Esri Leaflet","archived":false,"fork":false,"pushed_at":"2025-04-08T14:36:44.000Z","size":603,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-19T02:23:04.407Z","etag":null,"topics":["basemaps","esri","esri-leaflet","javascript","leaflet","leaflet-plugins","mapping"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Esri.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-08-20T20:22:35.000Z","updated_at":"2025-04-08T14:31:28.000Z","dependencies_parsed_at":null,"dependency_job_id":"aefa0507-17b3-4843-af58-2e3591cb4ad8","html_url":"https://github.com/Esri/esri-leaflet-static-basemap-tile","commit_stats":null,"previous_names":["esri/esri-leaflet-static-basemap-tile"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/Esri/esri-leaflet-static-basemap-tile","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Esri%2Fesri-leaflet-static-basemap-tile","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Esri%2Fesri-leaflet-static-basemap-tile/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Esri%2Fesri-leaflet-static-basemap-tile/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Esri%2Fesri-leaflet-static-basemap-tile/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Esri","download_url":"https://codeload.github.com/Esri/esri-leaflet-static-basemap-tile/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Esri%2Fesri-leaflet-static-basemap-tile/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29837421,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-25T19:08:47.527Z","status":"ssl_error","status_checked_at":"2026-02-25T18:59:04.705Z","response_time":61,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["basemaps","esri","esri-leaflet","javascript","leaflet","leaflet-plugins","mapping"],"created_at":"2025-06-09T17:08:19.825Z","updated_at":"2026-02-25T20:01:01.144Z","avatar_url":"https://github.com/Esri.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Esri Leaflet Static Basemap Tile Plugin\n\n[![npm version][npm-img]][npm-url]\n[![apache licensed](https://img.shields.io/badge/license-Apache%202.0-orange.svg?style=flat-square)](https://raw.githubusercontent.com/Esri/esri-leaflet-static-basemap-tile/master/LICENSE)\n[![jsDelivr Hits](https://data.jsdelivr.com/v1/package/npm/esri-leaflet-static-basemap-tile/badge)](https://www.jsdelivr.com/package/npm/esri-leaflet-static-basemap-tile)\n\n[npm-img]: https://img.shields.io/npm/v/esri-leaflet-static-basemap-tile.svg?style=flat-square\n[npm-url]: https://www.npmjs.com/package/esri-leaflet-static-basemap-tile\n\n\u003e A plugin for Esri Leaflet to visualize static basemap tiles \nfrom the static basemap tile service.\n\nThe Esri Leaflet Static Basemap Tile package provides a class to load static basemap tiles from the [ArcGIS static basemap tile service](https://developers.arcgis.com/rest/basemap-styles/). Basemaps are rendered as image tiles that adhere to the [OpenAPI specification](https://static-map-tiles-api.arcgis.com/arcgis/rest/services/static-basemap-tiles-service/v1/specification/open-api-v3-0/).\n\n## Example\n\nCheck out the [live demo]().\n\n![Example Image](example.png)\n\n```html\n\u003c!DOCTYPE html\u003e\n\u003chtml\u003e\n  \u003chead\u003e\n    \u003cmeta charset=\"utf-8\" /\u003e\n    \u003ctitle\u003eEsri Leaflet Static Basemap Tiles\u003c/title\u003e\n    \u003cmeta name=\"viewport\" content=\"width=device-width, initial-scale=1\" /\u003e\n\n    \u003c!-- Load Leaflet from CDN --\u003e\n    \u003clink rel=\"stylesheet\" href=\"https://unpkg.com/leaflet/dist/leaflet.css\" /\u003e\n    \u003cscript src=\"https://unpkg.com/leaflet/dist/leaflet.js\"\u003e\u003c/script\u003e\n\n    \u003c!-- Load Esri Leaflet --\u003e\n    \u003cscript src=\"https://unpkg.com/esri-leaflet/dist/esri-leaflet.js\"\u003e\u003c/script\u003e\n\n    \u003c!--  Load Esri Leaflet Static Basemap Tile --\u003e\n    \u003cscript src=\"https://unpkg.com/esri-leaflet-static-basemap-tile/dist/esri-leaflet-static-basemap-tile.js\"\u003e\u003c/script\u003e\n    \n    \u003cstyle\u003e\n      body {\n        margin: 0;\n        padding: 0;\n      }\n\n      #map {\n        position: absolute;\n        top: 0;\n        bottom: 0;\n        right: 0;\n        left: 0;\n      }\n    \u003c/style\u003e\n  \u003c/head\u003e\n\n  \u003cbody\u003e\n    \u003cdiv id=\"map\"\u003e\u003c/div\u003e\n\n    \u003cscript\u003e\n      var map = L.map(\"map\").setView([40.706, -73.926], 4);\n\n      L.esri.Static.staticBasemapTileLayer(\"arcgis/outdoor\", {\n        token: \"\u003c YOUR ARCGIS ACCESS TOKEN HERE \u003e\"\n      }).addTo(map);\n    \u003c/script\u003e\n  \u003c/body\u003e\n\n\u003c/html\u003e\n```\n\n## API Reference\n\n### [`L.esri.Static.staticBasemapTileLayer`]()\n\n`L.esri.Static.staticBasemapTileLayer(\u003cString\u003e style, \u003cObject\u003e options)`\n\nDisplays a basemap layer using tiles from the ArcGIS [Static basemap tiles service](https://developers.arcgis.com/rest/static-basemap-tiles/). Extends [L.TileLayer](https://leafletjs.com/reference.html#tilelayer).\n\n```js\nL.esri.Static.staticBasemapTileLayer(\"arcgis/streets\", {\n  token: \"\u003c YOUR ARCGIS ACCESS TOKEN HERE \u003e\"\n}).addTo(map);\n```\n\n```js\nL.esri.Static.staticBasemapTileLayer(\"arcgis/newspaper\", {\n  token: \"\u003c YOUR ARCGIS ACCESS TOKEN HERE \u003e\",\n  language: \"fr\"\n}).addTo(map);\n```\n\n* The `style` parameter must be a valid [basemap style code](#basemap-styles).\n\n* The `token` parameter must be a valid [ArcGIS access token](https://developers.arcgis.com/documentation/security-and-authentication/api-key-authentication/tutorials/create-an-api-key/).\n\nFor a full list of parameters, go to the Esri Leaflet [API reference]().\n\n#### Basemap Styles\n\n`staticBasemapTileLayer` accepts a basemap style enumeration as a string in the format `\u003cprovider\u003e/\u003cstyle\u003e`. For example, `arcgis/outdoor` will load the [ArcGIS Outdoor](https://developers.arcgis.com/rest/static-basemap-tiles/arcgis-outdoor-tile-get/) basemap style.\n\nFor a full list of supported basemap styles, go to the [static basemap tiles service documentation](https://developers.arcgis.com/rest/static-basemap-tiles/).\n\n### [`L.esri.Static.Util`]()\n\n`L.esri.Static.Util.getSelf(\u003cString\u003e token)`\n\nUtility method that makes a request to the [`/self`](https://developers.arcgis.com/rest/static-basemap-tiles/service-self-get/) endpoint of the ArcGIS static basemap tiles service. Requires a valid [ArcGIS access token](https://developers.arcgis.com/documentation/security-and-authentication/api-key-authentication/tutorials/create-an-api-key/).\n\nThis endpoint returns a list of all supported basemap styles and language parameters, which can be useful in creating maps that support multiple styles or languages.\n\n## Development Instructions\n\n### Quickstart Development Instructions\n\n1. [Fork and clone this repo](https://help.github.com/articles/fork-a-repo).\n2. `cd` into the `esri-leaflet-static-basemap-tile` folder.\n3. Install the dependencies with `npm install`.\n4. Run `npm run dev` to compile the raw source inside a newly created `dist` folder and start up a development web server.\n   - Alternatively, run `npm run start` to compile raw source code into both \"debug\" and \"production\" versions. This process will take longer to compile when saving your local changes to source code. Recommended only when building for production.\n5. Open `examples/quickstart-dev.html` to see local changes in action.\n\n### Advanced Development Instructions\n\n1. [Fork and clone this repo](https://help.github.com/articles/fork-a-repo).\n2. `cd` into the `esri-leaflet-static-basemap-tile` folder.\n3. Install the dependencies with `npm install`.\n4. Run `npm run build` to compile the raw source inside a newly created `dist` folder.\n5. Run `npm test` from the command line to execute tests.\n6. Open `examples/quickstart-dev.html` or `examples/quickstart-prod.html` to see local changes in action.\n7. Create a [pull request](https://help.github.com/articles/creating-a-pull-request) if you'd like to share your work.\n\n## Dependencies\n\n- Leaflet version [1.5.0](https://github.com/Leaflet/Leaflet/releases/tag/v1.5.0) (or higher) is required.\n- Esri Leaflet [2.3.0](https://github.com/Esri/esri-leaflet/releases/tag/v2.3.0) (or higher) is required.\n\n## Resources\n\n- [ArcGIS for Developers](http://developers.arcgis.com)\n- [ArcGIS REST Services](http://resources.arcgis.com/en/help/arcgis-rest-api/)\n- [@Esri](http://twitter.com/esri)\n\n## Issues\n\nFind a bug or want to request a new feature? Please let us know by submitting an [issue](https://github.com/Esri/esri-leaflet-static-basemap-tile/issues).\n\nPlease take a look at previous issues on [Esri Leaflet](https://github.com/Esri/esri-leaflet/issues?labels=FAQ\u0026milestone=\u0026page=1\u0026state=closed) that resolve common problems.\n\nYou can also post questions on the [GIS Stack Exchange](http://gis.stackexchange.com/questions/ask?tags=esri-leaflet,leaflet), as well as the [Open Source Mapping community](https://community.esri.com/t5/open-source-mapping-libraries-ques/bd-p/open-source-mapping-libraries-questions) on Esri forums.\n\n## Contributing\n\nEsri welcomes contributions from anyone and everyone. Please see our [guidelines for contributing](https://github.com/Esri/esri-leaflet/blob/master/CONTRIBUTING.md).\n\n## [Terms](https://github.com/Esri/esri-leaflet#terms)\n\n## Licensing\n\nCopyright \u0026copy; 2016-2024 Esri\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n\u003e http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nA copy of the license is available in the repository's [LICENSE](./LICENSE) file.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fesri%2Fesri-leaflet-static-basemap-tile","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fesri%2Fesri-leaflet-static-basemap-tile","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fesri%2Fesri-leaflet-static-basemap-tile/lists"}