File tree Expand file tree Collapse file tree 2 files changed +60
-1
lines changed Expand file tree Collapse file tree 2 files changed +60
-1
lines changed Original file line number Diff line number Diff line change
1
+ < html > </ html >
2
+
3
+ < head >
4
+ < meta charset ="utf-8 " />
5
+ < meta name ="viewport " content ="initial-scale=1,maximum-scale=1,user-scalable=no " />
6
+ < title > Esri Leaflet: Display static basemap tiles</ title >
7
+
8
+ <!-- Load Leaflet from local node_modules -->
9
+ < link rel ="stylesheet " href ="../node_modules/leaflet/dist/leaflet.css " />
10
+ < script src ="../node_modules/leaflet/dist/leaflet.js "> </ script >
11
+
12
+ <!-- Load Esri Leaflet production version -->
13
+ < script src ="../node_modules/esri-leaflet/dist/esri-leaflet.js "> </ script >
14
+
15
+ <!-- Load Esri Leaflet Static Basemap Tile production version -->
16
+ < script src ="../dist/esri-leaflet-static-basemap-tile.js "> </ script >
17
+
18
+ < style >
19
+ body {
20
+ margin : 0 ;
21
+ padding : 0 ;
22
+ }
23
+ # map {
24
+ position : absolute;
25
+ top : 0 ;
26
+ bottom : 0 ;
27
+ right : 0 ;
28
+ left : 0 ;
29
+ font-family : Arial, Helvetica, sans-serif;
30
+ font-size : 14px ;
31
+ color : # 323232 ;
32
+ }
33
+ </ style >
34
+ </ head >
35
+
36
+ < body >
37
+ < div id ="map "> </ div >
38
+
39
+ < script >
40
+
41
+ const map = L . map ( "map" , {
42
+ minZoom : 2
43
+ } )
44
+
45
+ map . setView ( [ 34.02 , - 118.805 ] , 13 ) ;
46
+
47
+ const accessToken = "YOUR_ACCESS_TOKEN" ;
48
+ const style = "arcgis/outdoor" ;
49
+
50
+ const layer = L . esri . Static . staticBasemapTileLayer ( style , {
51
+ token :accessToken ,
52
+ } )
53
+ layer . addTo ( map ) ;
54
+
55
+ </ script >
56
+
57
+ </ body >
58
+
59
+ </ html>
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " esri-leaflet-static-basemap-tile" ,
3
3
"description" : " Esri's static basemap tile layer plugin for Leaflet." ,
4
- "version" : " 1.0.0-beta.2 " ,
4
+ "version" : " 1.0.0" ,
5
5
"author" : " George Owen (https://www.linkedin.com/in/geoowen/)" ,
6
6
"contributors" : [
7
7
" Patrick Arlt <[email protected] > (http://patrickarlt.com)" ,
You can’t perform that action at this time.
0 commit comments