React Embedded AnalyticsStudio API Reference

To access the API, see Studio API.

Data

reloadCopy Link
Function
Reload all data from the data sources.

Lifecycle

destroyCopy Link
Function
Will destroy the Studio instance and release resources. If you are using a framework you do not need to call this, as Studio links in with the framework lifecycle. However if you are using native JavaScript, you need to call this to avoid a memory leak in your application.
getStudioIdCopy Link
Function
Returns the studioId for the current Studio instance as specified via the Studio property studioId or the auto assigned Studio ID if none was provided.

Properties

getPropertyCopy Link
Function
Returns the Studio properties value for a provided key.
setPropertyCopy Link
Function
Updates a single Studio property to the new value provided. (Cannot be used on Initial properties.) If updating multiple options, it is recommended to instead use api.updateProperties() which batches update logic.
updatePropertiesCopy Link
Function
Updates the provided subset of Studio properties with the provided values. (Cannot be used on Initial properties.)

State

getStateCopy Link
Function
Get the current state of Studio. Can be used in conjunction with the initialState Studio property or api.setState() to save and restore Studio state.
setStateCopy Link
Function
Set the current state of Studio. Can be used in conjunction with api.getState() or onStateUpdated to save and restore Studio state. The state is expected to be a full state object, not a partial state object. State must be updated immutably as Studio uses reference equality to determine which parts of state have changed.