UNPKG

573 BTypeScriptView Raw
1import { Statistic } from '../metric-types';
2export interface SimpleStatistic {
3 type: 'simple';
4 statistic: Statistic;
5}
6export interface PercentileStatistic {
7 type: 'percentile';
8 percentile: number;
9}
10export interface GenericStatistic {
11 type: 'generic';
12 statistic: string;
13}
14/**
15 * Parse a statistic, returning the type of metric that was used (simple or percentile)
16 */
17export declare function parseStatistic(stat: string): SimpleStatistic | PercentileStatistic | GenericStatistic;
18export declare function normalizeStatistic(stat: string): string;