🎉 Black Friday deal! 25% off your first year of CodyHouse Pro →

Projects

Progress value is 30%

Comments

Threaded comments template.

Copy: View demo

Dependencies

All components are built upon the CodyHouse Framework.

If you're using this component, you should also include the SCSS/JS of the following components:

This component includes variations. All variations share the same SCSS/JS code. They only differ in the HTML part.

How to

The Comments component is used to display a threaded comments section. It's often positioned at the end of blog posts (or similar content types).

Comment Likes #

When a user likes a comment (clicking the .js-comments__vote-btn element), a custom newVote event is emitted:

var commentBtnVote = document.getElementsByClassName('js-comments__vote-btn')[0]; // first comment vote Btn

commentBtnVote.addEventListener('newVote', function(event) {
  // user liked te comment
  // event.detail.count -> new value of cmment likes
  // event.detail.upVote -> true if the user liked the comment
});

✅ Project duplicated

✅ Project created

There was an error while trying to export your project. Please try again or contact us