This method of Esri Leaflet Vector allows you to provide a plugin that configures settings for right-to-left languages, such as Arabic and Hebrew. The most commonly passed option is the Mapbox GL RTL Text plugin, which Esri Leaflet Vector is compatible with since it uses Maplibre GL JS.
Method
Method | Description |
---|---|
L.esri.Vector.setRTLTextPlugin(<String> url, <ErrorCallback> callback, <Boolean> deferred) |
|
Example
const basemap = L.esri.Vector.vectorBasemapLayer('arcgis/outdoor',{
token:accessToken,
language:'ar' // Arabic
}).addTo(map);
L.esri.Vector.setRTLTextPlugin('https://unpkg.com/@mapbox/mapbox-gl-rtl-text@0.2.3/mapbox-gl-rtl-text.js');