Analytics Widgets

Analytics Widgets UI Extension for Umbraco Commerce

Analytics Widgets allow you to display custom charts and reports in the analytics section to track your important KPIs.

Analytics Widget

Registering an Analytics Widget

Each entry must have a type of ucAnalyticsWidget along with a unique alias and name. An element key should be defined to import the implementation of the UcAnalyticsWidget component interface.

A meta entry provides configuration options for the widget

Name
Description

label

A label for this widget (supports the # prefix localization string syntax)

description

A description for this widget (supports the # prefix localization string syntax)

The Analytics Widget element

In order to define the UI for a widget, you'll need to define a component that implements the UcAnalyticsWidget interface. This interface is defined as

This provides widget implementations with access to the current storeId, the defined manifest, and the current selected timeframe for which the widget should show relevant data.

An example implementation would be

When an alternative timeframe is selected from the widget dashboard, all widget's timeframe properties will be updated to re-fetch and render the widget.

Last updated

Was this helpful?