Function eventThreads

  • Filters the returned events so that the result is the events that are part of a thread.

    Threads are defined as a sequence of events that are related to each other and authored by the same user.

    Parameters

    • op: NDKEvent

      The original event

    • events: NDKEvent[]

      All candidate events (e.g. events tagging the OP)

    Returns NDKEvent[]

    The events that are part of the thread sorted by creation time