1. Install the comments app
# shell
pip install django-contrib-comments
2. Make migrations
# shell
python3 manage.py makemigrations
python3 manage.py migrate
3. Install the comments framework by adding django_comments
to INSTALLED_APPS
# settings.py
INSTALLED_APPS = [
"taggit",
"markdownx",
"django_comments"
]
4. Add the comment app’s URLs to your project’s urls.py
# urls.py
urlpatterns = [
# ...
path("comments/", include("django_comments.urls")),
]
5. Load the comment template tags in your template’s file
# html
{% load comments %}