GoodData.UI API reference
  • GoodData.UI
  • Docs & APIs
  • Developers
  • GoodData.CN
  • GoodData.UI
  • Docs & APIs
  • Get GoodData.CN Community Edition
  • 10.26.0
  • Code samples
  • Gallery
  • GitHub

addItemToPath()

Home > @gooddata/sdk-ui-dashboard > IFluidLayoutCustomizer > addItemToPath

IFluidLayoutCustomizer.addItemToPath() method

Adds a new item containing a custom widget onto the dashboard.

Signature:

addItemToPath(itemPath: ILayoutItemPath, item: IDashboardLayoutItem<ICustomWidget>): IFluidLayoutCustomizer;

Parameters

ParameterTypeDescription
itemPathILayoutItemPathlayout path where to add new item
itemIDashboardLayoutItem<ICustomWidget>item containing custom widget; note: customizer will make a deep copy of the item before adding it onto a dashboard. At this moment, the newly added items are read-only.

Returns:

IFluidLayoutCustomizer

Remarks

New item will be added to position defined by provided path allowing target also nested layouts/sections. All sections in path already need to exist. The item to add must contain a custom widget data. Attempts to add item that does not contain any widget data will be ignored and warnings will be reported. Keep in mind that this can lead to further errors or problems down the line if you are adding more items at specific indexes into the same section.

Note: new items will be added into existing sections before new sections will be added using the IFluidLayoutCustomizer.addSection method. Therefore,

  • IFluidLayoutCustomizer.addItemToPath() method
  • Parameters
  • Remarks
GoodData resources:
  • Documentation
Follow the community:
  • Community
Copyright © 2007–2025 GoodData Corporation. All Rights Reserved. Code licensed under a dual license - CC BY‑NC 4.0 for trial experience and GoodData.UI EULA for commercial use