After developing a few ArcGIS Online hosted templates, such as the Social Media and Public Gallery templates, we found that the need for a common starting point was clear. Our Technical Marketing team uses this boilerplate for new application development and it makes getting up and running much faster.
At their core, all of these applications can be configured and hosted on ArcGIS Online, take advantage of URL parameters to overwrite settings, and be localized in different languages. The boilerplate provides a framework for:
- Storing default application configuration options.
- Loading organization and configured application settings that overwrite default settings.
- Retrieving common URL parameters to configure the application.
- Setting up language files to store application strings for supporting multiple locales.
- Using a map from arcgis.com to drive your application.
- Managing an OAuth2 authentication workflow with ArcGIS Online.
- Getting started with hosted template configuration files.
The boilerplate is written in the Dojo Toolkit’s Asynchronous Module Definition (AMD) format, so you can maintain your code separately from the template specific logic. Whether you’re building a simple or complex application, the boilerplate can fit its size.
This bare-bones app includes all the code you need to start building an ArcGIS Online template. See the readme on GitHub for more information. We welcome you to contribute, fork the code, and report issues.
See you on GitHub!