hoangviet
(DilysLena)
5. November 2024 um 05:02
3
Ich habe hier ein Tutorial-Thema dafür gefunden.
Aber ich mache mir Sorgen, dass Ad-Blocker die Inhalte (HTML) unter diesen Beiträgen ausblenden werden.
Posts are widgets which means what you’re trying to do will involve a bit more work that just adding html.
Discourse themes have the ability to decorate widgets so you can leverage on that.
Decorating a widget is explained in the link above so let’s focus on what you’re trying to do - add markup after the first post in every topic.
Start by adding the markup to all posts. So something like this
<script type="text/discourse-plugin" version="0.8">
api.decorateWidget("post:after", helper => {
…