ContentCards

Hierarchy

  • ContentCards

Index

Constructors

constructor

  • A collection of Card descendents (ClassicCard, CaptionedImage, Banner). If you use Appboy's display module to render content cards, you generally shouldn't need to interact with this class, but if you are building your own content cards class manually, use appboy.getCachedContentCards to get the most recent ContentCards object.

    Parameters

    • cards: Card[]

      Array of Card descendents (ClassicCard, CaptionedImage, Banner).

    • lastUpdated: Date | null

      When this collection of cards was received from Appboy servers. If null, it means the content cards are still being fetched for this user.

    Returns ContentCards

Properties

cards

cards: Card[]

Array of Card descendents (ClassicCard, CaptionedImage, Banner).

lastUpdated

lastUpdated: Date | null

When this collection of cards was received from Appboy servers. If null, it means the content cards are still being fetched for this user.

Methods

getUnviewedCardCount

  • getUnviewedCardCount(): number
  • Get the current unviewed card count. This is useful for powering badges on your control for showing the content cards. ControlCard cards do not count towards the unviewed count.

    Returns number