elementAt()
elementAt: emit the value at zero-based index, then COMPLETE. EDGE (RxJS divergence, flagged):
RxJS throws ArgumentOutOfRangeError if the source completes before index; we COMPLETE without
a value (no throw), consistent with last/find.
Import
Section titled “Import”import { elementAt } from "@graphrefly/ts/operators";Signature
Section titled “Signature”function elementAt(index: number): Operator<S, S>Parameters
Section titled “Parameters”| Parameter | Type | Description |
|---|---|---|
index | number | index value used by the helper. |
Returns
Section titled “Returns”A Operator<S, S> value.
Example
Section titled “Example”import { elementAt } from "@graphrefly/ts/operators";Source
Section titled “Source”packages/ts/src/graph/operators.ts