This plugin for Discourse wraps <abbr>
HTML tags around a curated list of well known acronyms and abbreviations in posts, improving UX and SEO.
Demo
See it in action and test it out for yourself on our Crit Cola’s Discourse .
Installation
Add the plugin’s repository URL to your container’s app.yml
file, for example:
hooks:
after_code:
- exec:
cd: $home/plugins
cmd:
- mkdir -p plugins
- git clone https://github.com/critcola/discourse-post-abbreviations.git
Rebuild the container:
cd /var/discourse
./launcher rebuild app
For the plugin to apply retroactively, you’ll need to rebake old posts:
cd /var/discourse
./launcher enter app
rake posts:rebake
License
The Discourse Post Abbreviations plugin is released under the MIT License.
5 Likes
david
(David Taylor)
January 6, 2017, 3:56pm
2
How does this differ from this plugin?
I participate in a community where there are enthusiasts with lots of knowledge and newbies with not that much knowledge. It has become a habit that experts use lots of acronyms and abbreviations to refer to common terms, or famous webpages or to name known brands in their field of expertise, sometimes they use only initials when referring to famous people in the field, etc. This is not a problem for the oldest participants in the community, but some new people are having a hard time reading som…
1 Like
Mine is a curated list. Rather than everyone having to individually add hundreds of abbreviations and their variations, the community can contribute to a single, collective list of them.
3 Likes
tophee
(Christoph)
March 2, 2017, 12:58pm
4
But there is no easy way of providing that list list, right? I see it in the code on github, but how do I customize it?
You can customize it by forking the repository, then copying and pasting one of the lines (I have them in alphabetical order), substituting information in the regular expression where appropriate. If the acronyms could be useful to others, you can submit a pull request and I will merge your changes into the plugin’s repository.
If you need guidance on an example acronym, let me know and I can provide you with the code.
2 Likes
Is this plugin still working?
tophee
(Christoph)
July 18, 2018, 5:36pm
7
I’m not sure, but this does the job:
About
This theme component is ported from Linkify words in post to provide functionality similar to the Abbreviations and acronyms plugin – namely to wrap various abbreviations used in a given forum/site/Discourse installation in <abbr> tags.
Location
How to install
Credits
Thanks to @sam for writing the “Linkify words in post” plugin.
3 Likes