Placeholder
live example
Explore the API in the live example.
api reference
Placeholder()
Component implementing the placeholder feature. The placeholder is a blank div with a message in the middle that replaces the widget. It is useful when no data is available, or when the charts needs to be hidden/shown dynamically. When this component is available for a widget, its API is exposed directly via the widget's own namespace.
Placeholder.placeholder(content)
Shows/hides the placeholder. If no placeholder content is provided, the widget is recovered. Note that this only updates the status of the placeholder and the widget still needs to be rendered in order to take effect.
Parameters
Name | Type | Description |
---|---|---|
content | string | Content of the placeholder. Can be HTML formatted. If omitted, the placeholder is removed. Note that the content can be an empty string in which case the widget is simply hidden. |
Returns
Widget
Reference to the Widget's API.