Type Alias: DashboardProps

DashboardProps: ComponentProps & object

Defines the additional properties for an AnalyticsDashboard component

Type declaration 

customViewId? 

optional customViewId: string

The custom view ID to apply saved filter state to the dashboard. Used for preserving dashboard interactivity context (e.g., in Slack integrations).

hideHeader? 

optional hideHeader: boolean

Indicates whether the dashboard header is hidden (true) or not (false). Default is false.

pageName? 

optional pageName: string

The current page name for the dashboard.

Example 

1import {AnalyticsDashboard} from '@salesforce/analytics-embedding-sdk';
2import type {DashboardProps} from '@salesforce/analytics-embedding-sdk';
3
4const dashboardProps: DashboardProps = {
5    parentIdOrElement: 'dashboard-container',
6    idOrApiName: 'My_Dashboard_1',
7    pageName: 'Sales_Overview',
8    customViewId: 'f5f0e1234aabcde67890',
9    hideHeader: false
10};
11
12const dashboard = new AnalyticsDashboard(dashboardProps);
13await dashboard.render();

Multi-org Note: In multi-org scenarios, always specify the orgUrl property to indicate which org the dashboard exists in. The orgUrl must be a Lightning URL (e.g., https://yourorg.lightning.force.com).

DID THIS ARTICLE SOLVE YOUR ISSUE?
Let us know so we can improve!