Bookmark Data Source
7 min
overview the bookmark data source fetches the content items that the current user has bookmarked it is inherently user specific and auto refreshes reactively when the user adds or removes a bookmark — no manual reload required when to use this use bookmark on any view dedicated to showing a user's saved or bookmarked content basic example { "type" "bookmark", "contextkey" "bookmarks", "batchsize" 20 } configuration type specific properties property type default description filter storefrontcondition — a condition evaluated per bookmark — only bookmarks where the condition is true are included groupby issue boolean — when true , groups bookmarks by their associated issue for common properties ( contextkey , limit , batchsize , etc ) see todo insert link to data sources overview link filter unlike other data sources, filter here is a condition (not a query filter) evaluated individually for each bookmark the bookmark and its associated issue are available as $context bookmark and $context bookmark issue inside the condition example — include only bookmarks from a specific publication { "filter" { "value" "$context bookmark issue publicationid", "operation" "equals", "comparevalue" "\ publicationid" } } groupby issue when true , bookmarks are grouped by their associated issue groups are sorted by issue publication date (descending) within each group, bookmarks are ordered by page index then sequence number each group header exposes the following via $context group field description length number of bookmarks in this group contenttype content type of the group's items issuetype type of the associated issue sourceissue the issue object — available when the issue is known behavior notes default sort bookmarks are always sorted by creation date descending (most recently bookmarked first) this sort is fixed and cannot be overridden via config reactive refresh the data source automatically reloads when the user adds or removes a bookmark no view reload or manual state update is needed testing notes / edge cases filter is not a query all bookmarks are fetched first, then each is evaluated against the condition this affects performance for users with many bookmarks related topics todo insert link to data sources overview linktodo insert link to content data source link