You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
692 B

include comment
mixin renderCommentList (comments, options = { })
if Array.isArray(comments) && (comments.length > 0)
each comment in comments
li(data-comment-id= comment._id)
+renderComment(comment)
if (comments.length >= options.countPerPage)
- var buttonId = mongoose.Types.ObjectId();
li(data-button-id= buttonId).dtp-load-more.uk-text-center
button(
type="button",
data-button-id= buttonId,
data-post-id= post._id,
data-next-page= pagination.p + 1,
data-root-url= options.rootUrl,
onclick= `return dtp.app.loadMoreComments(event);`,
).uk-button.dtp-button-primary LOAD MORE