pond-ts API Reference (core)
    Preparing search index...

    Function top

    • Ergonomic helper: top(3) returns the literal 'top3' typed as `top${3}`. Use wherever an AggregateReducer name is accepted:

      series.aggregate(Sequence.every('1m'), { host: top(3) });
      series.arrayAggregate('tags', top(5));

      Equivalent to typing the string literal 'top3' directly.

      Type Parameters

      • N extends number

      Parameters

      Returns `top${N}`