mirror of
https://github.com/vale981/Vulcan
synced 2025-03-10 04:26:41 -04:00
17 lines
No EOL
545 B
JavaScript
17 lines
No EOL
545 B
JavaScript
const Post = (props) => {
|
|
({ListContainer, CommentList} = Telescope.components);
|
|
return (
|
|
<div className="post">
|
|
<h3>{props.title}</h3>
|
|
<p>{props.commentCount} comments</p>
|
|
<p>{moment(props.postedAt).fromNow()}</p>
|
|
<p>{props.body}</p>
|
|
<div className="comments-thread">
|
|
<h4>Comments</h4>
|
|
<ListContainer collection={Comments} publication="comments.list" terms={{postId: props._id, view: "postComments"}} component={CommentList} limit={0}/>
|
|
</div>
|
|
</div>
|
|
)
|
|
}
|
|
|
|
module.exports = Post; |