# Minor bug: syntax highlighting is not reapplied after editing a post

**URL:** https://meta.discourse.org/t/minor-bug-syntax-highlighting-is-not-reapplied-after-editing-a-post/24806
**Category:** Bug
**Created:** [February 4, 2015, 3:05pm UTC](https://meta.discourse.org/t/minor-bug-syntax-highlighting-is-not-reapplied-after-editing-a-post/24806 "2015-02-04T15:05:38Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![clay](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/clay/32/102156_2.png) [@clay](https://meta.discourse.org/u/clay)
#### Post date: [February 4, 2015, 3:05pm UTC](https://meta.discourse.org/t/minor-bug-syntax-highlighting-is-not-reapplied-after-editing-a-post/24806/1 "2015-02-04T15:05:38Z")

</div>

1. Create a post with some syntax highlighting:

```javascript
function myFunction(x) {
    console.log(x);
    return x;
}

```

1. Save the post.
2. Edit the post - add a character or something.
3. Save the post.

After step 4, the syntax highlighting is removed for that post. It doesn’t return until the page is refreshed.

---

<div class="post-metadata">

### Author: ![gerhard](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/gerhard/32/119479_2.png) [@gerhard](https://meta.discourse.org/u/gerhard)
#### Post date: [February 4, 2015, 4:00pm UTC](https://meta.discourse.org/t/minor-bug-syntax-highlighting-is-not-reapplied-after-editing-a-post/24806/2 "2015-02-04T16:00:17Z")

</div>

Duplicate of  
[https://meta.discourse.org/t/syntax-highlighting-does-not-appear-until-page-refresh/23548](https://meta.discourse.org/t/syntax-highlighting-does-not-appear-until-page-refresh/23548)

---

<div class="post-metadata">

### Author: ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)
#### Post date: [February 4, 2015, 4:12pm UTC](https://meta.discourse.org/t/minor-bug-syntax-highlighting-is-not-reapplied-after-editing-a-post/24806/3 "2015-02-04T16:12:47Z")

</div>


