Configuration
The <commentix-widget> HTML element accepts various attributes to configure the widget. See the list below for the
complete reference.
language
By default, the widget uses the language specified in the lang attribute on the document's <html> element.
If this attribute is not set or contains an unsupported language, it falls back to en.
Supported languages:
You can set the language attribute to one of the following language codes:
cz(Czech)da(Danish)de(German)el(Greek)en(English)es(Spanish)es-419(Spanish Latin America)fi(Finnish)fr(French)hu(Hungarian)it(Italian)nl(Dutch)no(Norwegian)pl(Polish)pt(Portuguese)pt-BR(Portuguese Brasil)ro(Romanian)ru(Russian)sv(Swedish)tr(Turkish)uk(Ukrainian)
Example:
maxLevels
This attribute sets the maximum number of nested comment replies. Restricting thread depth ensures conversations remain
readable and accessible, particularly on mobile devices. Once the limit is reached, the Reply button is automatically
hidden to prevent further nesting.
The default value of maxLevels is 3.
Example:
noCount
Set this attribute if you want to hide the number of comments next to the comment section title.
Example:
noRating
If you do not want users to be able to like comments, you can disable rating with this attribute.
Example:
page
To include accurate links in reply notification emails, the widget must transmit the parent page's URL to the backend. By default, the widget captures the current browser location, automatically stripping any query parameters or fragments (e.g., ?id=123 or #section).
For example, https://www.example.com/blog/article.html?id=value#some-anchor becomes
https://www.example.com/blog/article.html.
If the default detection is unsuitable for your use case, you can set this attribute to a canonical URL of your choice.
Example:
<commentix-widget site="{{ SITE_ID }}" page="https://www.example.com/blog/article.html?id=123"></commentix-widget>
sort
You can use this attribute to set the sort order of comments. Possible values are:
bestlatestoldest
The default value is best.
Example:
thread
All comments on your site are grouped in threads, and each thread belongs to a single page. By default, the widget uses
the pathname of the current browser location as the unique identifier of the thread. For example, if the widget is
embedded on https://www.example.com/en/blog/some-article.html?param=value, the thread ID will be
/en/blog/some-article.html.
This works out of the box in most cases. However, this default behavior might cause problems in the following cases:
- When the pathname changes, existing comments will not show up on the new address.
- On multilingual websites where the current language is not part of the pathname, the widget will show comments from all languages.
- Your backend uses custom IDs to identify pages or blog posts that are not part of the pathname (e.g. /blog/article?id=123).
- Different URLs pointing to the same page.
In those cases, it is highly recommended to set the thread attribute to a custom thread ID.
Example:
visibleComments
This attribute determines the number of root comments shown by default before showing the Show all comments button.
The default value is 5.
Example:
visibleLevels
Replies to comments are collapsed by default. You can use this attribute to show replies up to a certain level (depth).
The default value is 1.
Example: