Appearance
Persistence
js
new Insight('#chart', {
instanceId: 'revenue', // required for reliable reload + agent addressing
persist: false, // recommended for demos, QA, and dashboards
chartData,
});When persist: true, ChartBuddy stores chart state in localStorage keyed by instanceId. Edits checkpoint on Done (exitEditMode) and on destroy. Stale state can hide config fixes.
Clear:
js
import { clearPersistedChart } from '@chartbuddy.io/embed';
clearPersistedChart(/* optional instanceId */);For fixtures and agent QA, always use persist: false. Pass a stable instanceId whenever you need multi-chart addressing or intentional reload persistence.