{"componentChunkName":"component---src-templates-blog-post-js","path":"/how-to-show-comment-count-on-article-or-page/","result":{"data":{"site":{"siteMetadata":{"title":"Vuukle Docs","author":"Vuukle"}},"markdownRemark":{"id":"6f986ba0-e59b-5518-a3f6-aaac8710828e","html":"<p>In this modern day, user engagement is very important and you can improve it if you show comment count on your article or page.</p>\n<p>You can easily display comment count without adding any additional API calls on the page – simply add following HTML Data Attribute in the comment count anchor tag:</p>\n<p><code class=\"language-text\">&lt;a data=&quot;vuukle-count&quot; href=&quot;#vuukle-comments&quot;&gt;comments&lt;/a&gt;</code></p>\n<p>Also the count can be displayed with even more handy form:</p>\n<p><code class=\"language-text\">&lt;a href=&quot;#&quot;&gt;&lt;span data=&quot;vuukle-count&quot; data-empty-text=&quot;Add a&quot;&gt;0&lt;/span&gt; Comments&lt;/a&gt;</code></p>\n<p>To display the comment count for endless mode, the vuukle count element should be:</p>\n<p><code class=\"language-text\">&lt;a data=&quot;vuukle-count-[index]&quot; href=&quot;#vuukle-comments&quot;&gt;comments&lt;/a&gt;</code></p>\n<p>Also it can be:</p>\n<p><code class=\"language-text\">&lt;a href=&quot;#&quot;&gt;&lt;span data=&quot;vuukle-count-[index]&quot; data-empty-text=&quot;Add a&quot;&gt;0&lt;/span&gt; Comments&lt;/a&gt;</code></p>\n<p>Instead of <code class=\"language-text\">[index]</code>, you should use the index used to generate the widgets in endless mode.</p>","frontmatter":{"title":"How to show comment count on article or page","date":"May 01, 2017","category":"FAQ","tags":["how to","show","comment count"],"shortDescription":"In this modern day, user engagement is very important and you can improve it if you show comment count on your article or page."}}},"pageContext":{"id":"6f986ba0-e59b-5518-a3f6-aaac8710828e"}}}