Skip to main content

App setup

createUseCounts

Counts, from real use, the moments a person got stuck, so an agent has evidence from people's use. Counts only, and off by default: nothing is recorded until you call enable(), nothing leaves the page unless your own onReport sends it, and a report has no field for content or an identifier. Ouro UI has no collector and this reads and writes no storage, cookie or network.

import { createUseCounts } from "@/lib/ouro/use-counts";

Example

const counts = createUseCounts({ onReport: (report) => myAnalytics.send(report) });
if (userAgreedToCounts) counts.enable();
counts.record("disabled-press", { screen: "checkout", part: "pay-button" });
counts.flush();

Usage

Use it when you want evidence of where people get stuck in a shipped app.

Use instead when

  • Use Ouro check's --handoff kit instead when you can put a person in front of the app.

Parameters

options
Type: UseCountsOptions
{}

Returns

UseCounts