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

Function getPostTypeForCard

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

Source from the content-addressed store, hash-verified

157};
158
159const getPostTypeForCard = (post?: Post): PostType => {
160 if (!post) {
161 return PostType.Article;
162 }
163
164 if (isSocialTwitterPost(post)) {
165 return PostType.SocialTwitter;
166 }
167
168 return post.type;
169};
170
171type GetTagsProps = {
172 isListFeedLayout: boolean;

Callers 1

FeedItemComponentFunction · 0.85

Calls 1

isSocialTwitterPostFunction · 0.90

Tested by

no test coverage detected