Reactions
A reaction block any realm can embed. One line in your Render, no state on your side, and readers get one-click reactions keyed on the page they are looking at.
It is not a comment system, on purpose. There is no text field anywhere, which is what lets it run with no moderation: a closed palette, one reaction per address per page, changeable and removable.
It looks like this
๐ ๐ ๐ฅ ๐ ๐ 1 ๐
last ๐ by g1manfreโฆdlf5 ยท 1 reaction
That block is live and it is this realm's own page. Click one.
Add it to your realm
1import "gno.land/r/moul/reactions/v0"
2
3func Render(path string) string {
4 return body + reactions.RenderBlock()
5}
That is the whole integration. RenderBlock takes no argument because it does not need one: a plain read exported by one realm and called by another opens no realm frame, so it sees YOUR path and uses it as the page key. Nothing to register, nothing to configure.
For one block per article rather than one per realm, name the page yourself with the path you already serve:
1return body + reactions.RenderBlockFor("gno.land/r/you/blog:" + path)
Reactions are recorded here, not in your realm, so redeploying yours never loses them.
The palette
| key | |
|---|---|
up |
๐ |
heart |
๐ |
fire |
๐ฅ |
party |
๐ |
rocket |
๐ |
eyes |
๐ |
Six, and the set is closed. React aborts on anything else, which is the entire moderation policy.
The board
| page | reactions | last |
|---|---|---|
| gno.land/r/moul/home | 1 | ๐ g1manfreโฆdlf5 |
| gno.land/r/moul/reactions/v0 | 1 | ๐ g1manfreโฆdlf5 |