Introduction
Custom widgets extend the functionality and visualization capabilities of SAP Analytics Cloud. This lesson guides you through the process of importing a custom widget into SAP Analytics Cloud, allowing you to leverage community-developed or custom-built components within your dashboards and stories. By importing custom widgets, you can extend the standard features of SAP Analytics Cloud to meet specific analytical needs.
Before a custom widget can be used in a story, it must be imported into SAP Analytics Cloud. The import process registers the widget so that it becomes available in the widget panel.
At a conceptual level, importing a custom widget involves:
- uploading the custom widget JSON file, which defines the widget metadata,
- making the widget’s resource files available, depending on the chosen hosting approach.
Once imported, the custom widget behaves like any other component from a story author’s perspective and can be reused across multiple stories.
Import Process
The process of importing a custom widget into SAP Analytics Cloud involves several key steps, from locating the widget files to uploading them into your SAP Analytics Cloud environment. Custom widgets are typically distributed as a JSON file and resource files (such as JavaScript files), which may be provided individually or as a ZIP archive.
The first step is to obtain the necessary files for the custom widget you wish to import. A common source for sample widgets is the SAP Samples Repository on GitHub. It contains a collection of custom widgets contributed by the SAP Community.
Once you've located the desired widget, you need to download the associated files. Typically, you need at least a JavaScript file and a JSON file. Some folders may also include a ZIP file containing these two files and other resources.
If the folder doesn't include a prepackaged ZIP file, you need to create one manually. This involves compressing all resource .js files into a single archive.
With the necessary files prepared, you can now import the custom widget into your SAP Analytics Cloud environment.
After the import, you can use the custom widget just like you use any other component, including reusing it in other stories.
By following these steps, you can successfully import and use custom widgets in SAP Analytics Cloud, enhancing your analytical capabilities and creating more engaging visualizations.
Summary
- A custom widget requires a JSON file and one or more resource files (such as JavaScript files).
- Creating a ZIP archive may be necessary.
- Importing the widget involves uploading the ZIP and JSON files.