# Discourse Mark Plugin

**URL:** https://meta.discourse.org/t/discourse-mark-plugin/93059
**Category:** Plugin
**Tags:** deprecated
**Created:** [July 25, 2018, 2:12am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059 "2018-07-25T02:12:04Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![sirideain](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sirideain/32/101202_2.png) [@sirideain](https://meta.discourse.org/u/sirideain)
#### Post date: [July 25, 2018, 2:12am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/1 "2018-07-25T02:12:04Z")

</div>

> [@JammyDodger](#):
>
> The `<mark>` tag is now supported in core so you could manually add the tags for a similar effect:
> 
> `<mark>highlighted text</mark>`
> 
> highlighted text
> 
> You could also now map it to a toolbar button with a simple theme component. 👍

# discourse-mark

Repository: [GitHub - sirideain/discourse-mark: Adds highlighting to Discourse · GitHub](https://github.com/sirideain/discourse-mark)

 ![2018-07-24_22-01-29](https://global.discourse-cdn.com/meta/original/3X/0/d/0d79a6a8d514cc4a7e26d5713ee72e12790fbbf2.gif)

## Features

- Adds an editor option to highlight text.

## Usage

You can wrap text with == to highlight it.

`==Highlighted Text==`

## Installation

> [@Install plugins on a self-hosted site](https://meta.discourse.org/t/install-a-plugin/19157):
>
> warning This guide assumes that you have a self-hosted standard installation. We only support the standard method of install here, so these instructions assume you have a [standard install](https://meta.discourse.org/t/142537?silent=true). warning This guide only applies to self-hosted Discourse instances. If you are using a managed hosting service, the available plugins are controlled by your hosting provider. For example, on our hosting [these specific plugins](https://www.discourse.org/plugins) are available by hosting tier. information_source As of mid-2025, [many p…](https://meta.discourse.org/t/373574)

## Known Issues

- None

## Future

- Update icon to highlighter once Font Awesome 5 is available

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [July 25, 2018, 3:52am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/2 "2018-07-25T03:52:49Z")

</div>

This is already sort of possible in default Discourse with HTML tags

inserted text and ~~deleted text~~

`<ins>inserted text</ins> and <del>deleted text</del>`

Not quite the same as “highlighted” but a very similar effect at least for `<ins>`

---

<div class="post-metadata">

### Author: ![Stephen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/stephen/32/95011_2.png) [@Stephen](https://meta.discourse.org/u/Stephen)
#### Post date: [July 25, 2018, 4:15am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/3 "2018-07-25T04:15:57Z")

</div>

I think @sirideain put this together following this thread: [Discourse CommonMark text highlighting?](https://meta.discourse.org/t/discourse-commonmark-text-highlighting/92936)

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [July 25, 2018, 4:17am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/4 "2018-07-25T04:17:23Z")

</div>

Yes totally fine, just pointing out there’s an alternative “sort-of” way to do this built in. I don’t think Commonmark even specifies highlight as part of the standard…

---

<div class="post-metadata">

### Author: ![Stephen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/stephen/32/95011_2.png) [@Stephen](https://meta.discourse.org/u/Stephen)
#### Post date: [July 25, 2018, 4:18am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/5 "2018-07-25T04:18:53Z")

</div>

> [@codinghorror](#):
>
> es totally fine, just pointing out there’s an alternative “sort of” way to do this built in.

I think they’re fundamentally different things though? Insertions and deletions may be used in parallel with highlighting.

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [July 25, 2018, 4:19am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/6 "2018-07-25T04:19:40Z")

</div>

That’s a very literal reading. If I was to tell you I just highlighted this text how would anyone reading even know any different? Particularly if I changed the CSS to whatever color and style I liked..

---

<div class="post-metadata">

### Author: ![Stephen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/stephen/32/95011_2.png) [@Stephen](https://meta.discourse.org/u/Stephen)
#### Post date: [July 25, 2018, 7:23am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/7 "2018-07-25T07:23:36Z")

</div>

Highlighting indicates areas for attention, insertions and deletions indicate change.

Sure, we can use CSS to restyle elements, we could also for example set background-color on anything within `<strong>` tags, but then we would lose the ability to make things bold without also highlighting them. The plugin lets us highlight passages without losing differentiation between the styles associated with tracked changes. Being a totally optional plugin which expands upon a well-established convention I don’t see tremendous value in confusing the two.

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [July 25, 2018, 7:25am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/8 "2018-07-25T07:25:37Z")

</div>

It is not part of the commonmark spec, that is for sure.

---

<div class="post-metadata">

### Author: ![justin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/justin/32/157614_2.png) [@justin](https://meta.discourse.org/u/justin)
#### Post date: [July 26, 2018, 3:05pm UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/9 "2018-07-26T15:05:46Z")

</div>

It would be great if this followed other common Markdown highlight syntax. I’m not sure if it’s in a particular spec (a quick Google search didn’t yield anything), but popular Markdown apps with the highlight feature use double colons to enclose text, like so:

```
::Highlighted Text::

```

Love the idea though!

---

<div class="post-metadata">

### Author: ![sirideain](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sirideain/32/101202_2.png) [@sirideain](https://meta.discourse.org/u/sirideain)
#### Post date: [July 26, 2018, 3:21pm UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/10 "2018-07-26T15:21:54Z")

</div>

Discourse is using markdown-it for parsing markdown. I am bundling the [markdown-it-mark](https://github.com/markdown-it/markdown-it-mark) plugin so it is available in Discourse. Support for this syntax would need to be added there.

---

<div class="post-metadata">

### Author: ![peternlewis](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/peternlewis/32/108888_2.png) [@peternlewis](https://meta.discourse.org/u/peternlewis)
#### Post date: [August 1, 2018, 4:35am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/11 "2018-08-01T04:35:19Z")

</div>

I installed this, and the `==text==` highlighting works, but the Highlight Text option does not show up in the gear menu.

Curiously the Green Tick does not show next to the plugin either:

 ![image](https://global.discourse-cdn.com/meta/original/3X/f/0/f0b55471493172981cd5213ac518ef735db67dee.png)

but I don’t know if that is related.

---

<div class="post-metadata">

### Author: ![featheredtoast](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/featheredtoast/32/116994_2.png) [@featheredtoast](https://meta.discourse.org/u/featheredtoast)
#### Post date: [August 1, 2018, 5:57am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/12 "2018-08-01T05:57:50Z")

</div>

The green tick will only appear next to **official** plugins that are supported by the core discourse team, to distinguish them from 3rd party plugins.

---

<div class="post-metadata">

### Author: ![sirideain](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sirideain/32/101202_2.png) [@sirideain](https://meta.discourse.org/u/sirideain)
#### Post date: [August 1, 2018, 12:40pm UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/13 "2018-08-01T12:40:42Z")

</div>

There was an issue where the highlighting was not respecting the enable setting, but the gear menu option was. This has been fixed now.

---

<div class="post-metadata">

### Author: ![peternlewis](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/peternlewis/32/108888_2.png) [@peternlewis](https://meta.discourse.org/u/peternlewis)
#### Post date: [December 3, 2020, 12:48am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/14 "2020-12-03T00:48:30Z")

</div>

This plugin appears to break posting in Discourse 2.6. At least, posting failed with error 500 until I removed this plugin and rebuilt my forum.

---

<div class="post-metadata">

### Author: ![sirideain](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sirideain/32/101202_2.png) [@sirideain](https://meta.discourse.org/u/sirideain)
#### Post date: [December 3, 2020, 2:22am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/15 "2020-12-03T02:22:46Z")

</div>

I just tested with a fresh install of 2.7 beta1 and it seems to be working correctly. What other plugins do you have installed? Is there anything in the Discourse logs?

---

<div class="post-metadata">

### Author: ![peternlewis](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/peternlewis/32/108888_2.png) [@peternlewis](https://meta.discourse.org/u/peternlewis)
#### Post date: [December 3, 2020, 6:18am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/16 "2020-12-03T06:18:18Z")

</div>

See:

> [@Cannot post or edit after updating to 2.6](https://meta.discourse.org/t/cannot-post-or-edit-after-updating-to-2-6/172052):
>
> I updated to version 2.6 (on a Digital Ocean instance), and I can no longer post. “Error 500” when posting. Logs show: I tried restarting the server, no change. safe-mode has no affect, the problem remains. Help?

It is possible the rebuild was all that was required, though the error logs do mention markdown.

The other plugins are all Discourse first party ones.

---

<div class="post-metadata">

### Author: ![sirideain](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sirideain/32/101202_2.png) [@sirideain](https://meta.discourse.org/u/sirideain)
#### Post date: [December 3, 2020, 4:43pm UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/17 "2020-12-03T16:43:52Z")

</div>

I tried adding in the other plugins you listed and I was not able reproduce the issue.

I am not surprised the logs listed markdown as that is used for all formatting in Discourse posts. I didn’t see any mention of this plugin in the logs you posted.

What happens if you add the plugin back in and rebuild again? I think your idea that it was the rebuild is accurate.

---

<div class="post-metadata">

### Author: ![peternlewis](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/peternlewis/32/108888_2.png) [@peternlewis](https://meta.discourse.org/u/peternlewis)
#### Post date: [December 4, 2020, 2:25am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/18 "2020-12-04T02:25:22Z")

</div>

> [@sirideain](#):
>
> What happens if you add the plugin back in and rebuild again? I think your idea that it was the rebuild is accurate.

I will try that and get back to you. I might not be able to get it done today, I need to do it when I have some time to track it carefully.

Thanks for the feedback.

---

<div class="post-metadata">

### Author: ![peternlewis](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/peternlewis/32/108888_2.png) [@peternlewis](https://meta.discourse.org/u/peternlewis)
#### Post date: [December 7, 2020, 3:02am UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/19 "2020-12-07T03:02:50Z")

</div>

I reinstalled the mark plugin and everything seems fine, so some combination of removing the plugin and rebuilding resolved the inability to post, and reinstalling the plugin and rebuilding did not return to the failure state.

Who knows what that means, but I’m happy to have the plugin back.

Thanks.

---

<div class="post-metadata">

### Author: ![emyoulation](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/emyoulation/32/165545_2.png) [@emyoulation](https://meta.discourse.org/u/emyoulation)
#### Post date: [June 6, 2021, 6:13pm UTC](https://meta.discourse.org/t/discourse-mark-plugin/93059/20 "2021-06-06T18:13:49Z")

</div>

> [@codinghorror](#):
>
> This is already sort of possible in default Discourse with HTML tags
> 
> inserted text and ~~deleted text~~
> 
> `<ins>inserted text</ins> and <del>deleted text</del>`
> 
> Not quite the same as “highlighted” but a very similar effect at least for `<ins>`

Is there a way to add styling shortcuts to the Post editor’s toolbar? There are a number of tags that would improve the comprehension of technical topics. But newbies, on the other hand, are frustrated by the austerity of the Discourse toolbar.

Perhaps we could have toolbar options for a few Markdown tags we can use to make our posts more readable. Your example of Insert & ~~Delete~~ are very practical. This plus the keyboard button tag already clarify our postings by experienced regulars.

And since we are doing community-powered software support, a customizable emoji group (floated to the top/default) would be helpful. (We’d add a [technology emoji group](https://emojiguide.org/search?q=technology).)

inserted code : `<ins>`inserted code`</ins>`  
~~deleted code~~ : `<del>`deleted code`</del>`  
marked text : `<mark>`marked text`</mark>`  
Keyboard keys Ctrl+k : `<kbd>`Ctrl`</kbd>`+`<kbd>`k`</kbd>`

Technology emojis include input devices like the mouse & keyboard.  
🖱 Computer Mouse

[Next page](https://meta.discourse.org/t/discourse-mark-plugin/93059.md?page=2)
