Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/kiranandcode/simple-pleroma-comments
Free, open source web commenting system in a single script (no-analytics, privacy friendly)!
https://github.com/kiranandcode/simple-pleroma-comments
activitypub comments comments-system ocaml pleroma privacy
Last synced: 8 days ago
JSON representation
Free, open source web commenting system in a single script (no-analytics, privacy friendly)!
- Host: GitHub
- URL: https://github.com/kiranandcode/simple-pleroma-comments
- Owner: kiranandcode
- License: gpl-3.0
- Created: 2020-07-15T08:50:22.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2021-08-31T04:02:56.000Z (about 3 years ago)
- Last Synced: 2024-07-20T19:11:13.406Z (4 months ago)
- Topics: activitypub, comments, comments-system, ocaml, pleroma, privacy
- Language: OCaml
- Homepage:
- Size: 62.5 KB
- Stars: 16
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
# Pleroma Comments
*Privacy respecting FOSS comments system for static webpages.*![pleroma-comments-example-image](https://github.com/Gopiandcode/pleroma-comments/raw/master/example.png)
Having comments can be a great way to spice up a blog or personal
site, however most popular solutions for online comments (looking at
you Disqus) are proprietary non-free privacy-disrespecting ~~pieces of
trash~~ *ahem* software.## Dependencies
I *hate* Javascript and refuse to write a single line of that godforsaken language.As such, this plugin is actually built by transpiling from `Ocaml`.
To build the plugin, you'll need the following dependencies:
`
core_kernel
base
js_of_ocaml-tyxml
js_of_ocaml
js_of_ocaml-lwt
cohttp
cohttp-lwt-jsoo
lwt
yojson
`
All of these can be installed from opam using `opam install `.## Building
To build the plugin:1. open the `pleroma_comments.ml` file and edit:
- `instance_url` - to your home pleroma instance (default: "https://mastadon.social.com")
- `base_comment_id` - the id of the element that pleroma-comments will as the insertion point (default: "comments")
- `reply_icon_url` - icon of reply2. run `opam build ./pleroma_comments.js`
3. exported javascript can be found at `./_build/default/pleroma_comment.js`
4. (optional) open `./_build/default/index.html` to test whether the package works (you may need to modify the comment id).
## Usage
The idea of this plugin builds on the idea presented in this
[blog-post](https://ecmelberk.com/fediverse-comments.html) by Ecmel
Berk Canlıer.When you want to support comments for a blog or page, first share the
page on the fediverse in dedicated post. Pleroma-comments will then
read any responses to this post and pretty print them on the base html
page.Assuming you've made a post on the Fediverse, and have since found your post's id.
Simply add the script to your server (also update your [JS-licences](https://www.gnu.org/licenses/javascript-labels.html) to mention it's FOSS), and load the script in the head of your page:
``````
When you want comments, place a div into your static page - the only contents of the div should be the ID of your post.
```9x4Lf0vc7HBztCRDfM
```On loading the page, pleroma-comments will replace this element with html representing the comments:
```
```
Style as you need.
Kiran Gopinathan
Posted on07:44, 2nd of Jun, 2020
reply
Kiran Gopinathan
Posted on13:10, 2nd of Jun, 2020
reply
reply