Geographic Information Systems Asked by digz6666 on November 1, 2021
I’m looking for ways to customize built in widgets, but couldn’t find anything in version 4.x.
In version 3.x you can do it in following way as mentioned in doc https://developers.arcgis.com/javascript/3/jshelp/localization.html:
var map;
require(["esri/map", "dojo/i18n!esri/nls/jsapi", "dojo/domReady!"],
function(Map, bundle) {
bundle.widgets.homeButton.home.title = 'Эзэмшлийн газар'
}
);
But in version 4.x, there’s only way to customize DOJO text, not arcgis:
https://developers.arcgis.com/javascript/latest/guide/localization/index.html
I think, theoretically, it is possible to npm install
JS API from Esri GitHub repository, and before making a Custom Build of JS API edit strings in localization files — they are situated in t9n folders.
https://github.com/Esri/arcgis-js-api/tree/4master
Second approach, for widgets, is to create your own view and use your own localization and UI components. You can use ViewModels of the widgets from JS API accordingly.
Answered by ZdenekJ. on November 1, 2021
Get help from others!
Recent Answers
Recent Questions
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP