Class Comment

A comment on a user profile.

Implements

Constructors

  • Parameters

    • client: Client

      The main client.

    • data: {
          comment_markdown: string;
          comment_rendered_html: string;
          created_at: Date;
          default_avatar_color_index: number;
          default_avatar_index: number;
          maybe_edited_at: null | Date;
          token: string;
          updated_at: Date;
          user_display_name: string;
          user_gravatar_hash: string;
          user_token: string;
          username: string;
      }

      The raw comment data from the FakeYou API.

      • comment_markdown: string
      • comment_rendered_html: string
      • created_at: Date
      • default_avatar_color_index: number
      • default_avatar_index: number
      • maybe_edited_at: null | Date
      • token: string
      • updated_at: Date
      • user_display_name: string
      • user_gravatar_hash: string
      • user_token: string
      • username: string

    Returns Comment

Properties

client: Client
commentMarkdown: string
commentRenderedHtml: string
createdAt: Date
defaultAvatarColorIndex: number
defaultAvatarIndex: number
fetchProfile: ((this) => Promise<ProfileUser | undefined>) = implFetchUser

Fetch the user profile of the user who left the comment.

Type declaration

    • (this): Promise<ProfileUser | undefined>
    • Fetch the user profile of the user who left the comment.

      Parameters

      Returns Promise<ProfileUser | undefined>

maybeEditedAt: null | Date
token: string

The token of the comment. This is NOT the author's user token.

updatedAt: Date
userDisplayName: string

The display name of the user who left the comment.

userGravatarHash: string
userToken: string

The token of the user who left the comment.

username: string

The username of the user who left the comment.

Generated using TypeDoc