Hooks
Komments fires several hooks when data changes, comments get published or are modified in any way. You can use those to perform actions like flushing your page cache.
The following hooks are available:
| hook | data | description |
|---|---|---|
komments.comment.replied |
comment | When somebody replies to a comment, this hook is fired |
komments.comment.published |
comment | When a comment is published this hook is fired |
komments.comment.received |
comment | When a new comment was submitted, this hook fires |
komments.comment.changed |
array of ids | When a comment changed in any way, this hook fires |
komments.comment.deleted |
array of ids | When one or multiple comments are deleted, this hook fires |
komments.comment.flagged |
array of ids | When one or mulitple comments are flagged, this hook fires. |
Learn more about Kirby hooks and how to use them here: https://getkirby.com/docs/reference/plugins/extensions/hooks#registering-hooks__in-your-config