skip to main content

@tonyfast s notebooks

site navigation
notebook summary
title
adding giscus comments to this blog
description
i've wanted comments for a bit. i didn't realize what a can of worms this decision was. during the day i implemented:
cells
6 total
2 code
state
executed out of order
kernel
Python [conda env:root] *
language
python
name
conda-root-py
lines of code
15
outputs
0
table of contents
{"kernelspec": {"display_name": "Python [conda env:root] *", "language": "python", "name": "conda-root-py"}, "language_info": {"codemirror_mode": {"name": "ipython", "version": 3}, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.9.13"}, "widgets": {"application/vnd.jupyter.widget-state+json": {"state": {}, "version_major": 2, "version_minor": 0}}, "title": "adding giscus comments to this blog", "description": "i've wanted comments for a bit. i didn't realize what a can of worms this decision was.\nduring the day i implemented:"}
notebook toolbar
Activate
cell ordering
1

adding giscus comments to this blog

i've wanted comments for a bit. i didn't realize what a can of worms this decision was. during the day i implemented:

2

the diff

3

the new comment system was added by overriding the commments.html partial.

4
    if I := "__file__" not in locals():
        !cd ../.. && git log --name-only --pretty=oneline 8f808b9208e8226b68a243882b5738258d1a6c72..c184b6d10b3405b2b0e227b21dc37c5285800214
5

the file

the snippet in generated by the giscus app . everything needs to be filled out!

6
    if I:
        import pathlib, IPython
        display(IPython.display.Code(pathlib.Path("../../overrides/partials/comments.html").read_text(), language="html"))