Flarum (2.x)
    Preparing search index...
    Index
    animateScroll: boolean = false
    description: string = ''

    The description to render on the scrubber.

    discussion: Discussion

    The discussion to display the post stream for.

    forceUpdateScrubber: boolean = false

    When the page is scrolled, goToIndex is called, or the page is loaded, various listeners result in the scrubber being updated with a new position and values. However, if goToNumber is called, the scrubber will not be updated. Accordingly, we add logic to the scrubber's onupdate to update itself, but only when needed, as indicated by this property.

    index: number = 0
    loadNext: () => void
    loadPageTimeouts: Record<number, NodeJS.Timeout> = {}
    loadPrevious: () => void
    loadPromise: Promise<void> | null = null
    needsScroll: boolean = false
    number: number = 1
    pagesLoading: number = 0
    paused: boolean = false

    Whether or not the infinite-scrolling auto-load functionality is disabled.

    targetPost: { number: number } | { index: number; reply?: boolean } | null = null
    visible: number = 1

    The number of posts that are currently visible in the viewport.

    visibleEnd: number = 0
    visibleStart: number = 0
    loadCount: number = 20

    The number of posts to load per page.

    • A jump whose posts failed to load. The request has shown its own error; the stream stops waiting for the jump, so the reader can scroll and the page that asked for it (such as a discussion still loading) can carry on.

      Returns void

    • Reset the stream so that a specific range of posts is displayed. If a range is not specified, the first page of posts will be displayed.

      Parameters

      • Optionalstart: number
      • Optionalend: number

      Returns void

    • Load through to the latest post in the discussion, expanding the visible window to the end of the stream. Unlike update(), this places no bound on how far the window has fallen behind — the caller is responsible for ensuring the end was being viewed before the posts being caught up on entered the store.

      Returns Promise<Post[]>

    • Update the stream so that it loads and includes the latest posts in the discussion, if the end is being viewed.

      Note: viewingEnd() tolerates a drift of at most one post, so this is only suitable when the store has gained a single new post since the window was last synced (the live-event case). When several posts land in the store at once — e.g. they were missed while a realtime connection was down — capture viewingEnd() BEFORE pushing the new payloads and call syncEnd() directly instead.

      Returns Promise<void> | Promise<Post[]>