:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
import { defineNotebookWidgetViews } from 'scenes/notebooks/notebookWidgetCatalog'
import { NotebookNodeProps } from 'scenes/notebooks/types'
import { NotebookExperimentComponent } from './NotebookExperimentComponent'
export type ExperimentNotebookWidgetAttributes = {
id: number
view?: string
}
function ExperimentCompactSummary({ attributes }: NotebookNodeProps<ExperimentNotebookWidgetAttributes>): JSX.Element {
return <NotebookExperimentComponent id={attributes.id} expanded={false} />
}
function ExperimentResults({ attributes }: NotebookNodeProps<ExperimentNotebookWidgetAttributes>): JSX.Element {
return <NotebookExperimentComponent id={attributes.id} expanded />
}
export const EXPERIMENT_NOTEBOOK_WIDGET_VIEWS = defineNotebookWidgetViews<
ExperimentNotebookWidgetAttributes,
'Experiment'
>('Experiment', {
summary: ExperimentCompactSummary,
results: ExperimentResults,
})