Skip to main content

Class: CommentTree<T\>

Type parameters#

NameDefault
TSubmission | FullComment

Properties#

allComments#

• allComments: (Comment | FullComment)[]= []

Already loaded and comment that can be loaded later as single objects

Defined in: objects/post/comment/tree.ts:17


loadedComments#

• loadedComments: FullComment[]= []

Already loaded comments

Defined in: objects/post/comment/tree.ts:14


parent#

• parent: T

The comment above this or the submission in case of a top comment

Defined in: objects/post/comment/tree.ts:11


r#

• r: Reddit

Defined in: objects/post/comment/tree.ts:5


submission#

• submission: Submission

The submission this comment was posted under

Defined in: objects/post/comment/tree.ts:8

Methods#

fetchAll#

â–¸ fetchAll(): Promise<(null | FullComment)[]>

Fetch all not fetched comments and return them together with the loadedComments comments

Returns: Promise<(null | FullComment)[]>

the comment or null if it has been deleted

Defined in: objects/post/comment/tree.ts:48


fetchMissing#

â–¸ fetchMissing(): Promise<(null | FullComment)[]>

Fetch all not fetched comments

Returns: Promise<(null | FullComment)[]>

the comment or null if it has been deleted

Defined in: objects/post/comment/tree.ts:65