MCPcopy Create free account
hub / github.com/dailydotdev/apps / getReadArticleHref

Function getReadArticleHref

packages/shared/src/graphql/posts.ts:130–133  ·  view source on GitHub ↗
(
  post: Pick<Post, 'type' | 'subType' | 'sharedPost' | 'permalink'>,
)

Source from the content-addressed store, hash-verified

128 * otherwise the post's own permalink.
129 */
130export const getReadArticleHref = (
131 post: Pick<Post, 'type' | 'subType' | 'sharedPost' | 'permalink'>,
132): string | undefined =>
133 getPostReadTarget(post).target?.permalink ?? post.permalink;
134
135export const getReadPostButtonText = (post: Post): string => {
136 if (isVideoPost(post)) {

Callers 3

PostHeaderActionsFunction · 0.90
ReaderPostLayoutFunction · 0.90
PostFocusCardFunction · 0.90

Calls 1

getPostReadTargetFunction · 0.85

Tested by

no test coverage detected