Funnel

How many make it through each step, and where they drop off.

  1. Visited pricing48,210
  2. Started a trial6,90414% of Visited pricing
    , 14% of the step before
  3. Invited a teammate2,8716% of Visited pricing
    , 42% of the step before
  4. Connected a repository1,9664.1% of Visited pricing
    , 68% of the step before
  5. Upgraded to paid7421.5% of Visited pricing
    , 38% of the step before

Installation

pnpm dlx shadcn@latest add checkfu/uicontext/funnel

Usage

import type { ChartDatum } from "./ui/uicontext/components/charts/Data.ts"import { Funnel } from "./ui/uicontext/components/charts/Funnel.ts"
export const TrialFunnel = <M>(h: Html.H<M>, steps: ReadonlyArray<ChartDatum>) =>	Funnel(h, { label: "Trial to paid, last 30 days", steps })

Examples

Pick a step

Steps as buttons, to filter a report.

  1. , 14% of the step before
  2. , 42% of the step before
  3. , 68% of the step before
  4. , 38% of the step before

Pick a step to see who stopped there.

API reference

Options

Funnel options
NameTypeDescription
labelrequiredstring—
stepsrequiredChartDatum[]—
formatChartFormat—
colorChartColor—
selectedstringThe step that's picked, drawn as pressed
select((id: string) => Message)Makes each step a button that sends this
localestring—
styleStyle—

Accessibility

  • An ordered list: each step reads its count, its share of the first step and of the step before.
  • When steps can be picked they're toggle buttons (aria-pressed).

Source