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

Function getPostTypeForCard

packages/shared/src/components/FeedItemComponent.tsx:135–145  ·  view source on GitHub ↗
(post?: Post)

Source from the content-addressed store, hash-verified

133}
134
135const getPostTypeForCard = (post?: Post): PostType => {
136 if (!post) {
137 return PostType.Article;
138 }
139
140 if (isSocialTwitterPost(post)) {
141 return PostType.SocialTwitter;
142 }
143
144 return post.type;
145};
146
147type GetTagsProps = {
148 isListFeedLayout: boolean;

Callers 1

FeedItemComponentFunction · 0.85

Calls 1

isSocialTwitterPostFunction · 0.90

Tested by

no test coverage detected