# Whether support code(C/C++,java,js...) syntax highlighting in future?

**URL:** <https://forum.mattermost.com/t/whether-support-code-c-c-java-js-syntax-highlighting-in-future/1347>\
**Category:** Troubleshooting\
**Created:** [April 19, 2016, 5:29pm UTC](https://forum.mattermost.com/t/whether-support-code-c-c-java-js-syntax-highlighting-in-future/1347 "2016-04-19T17:29:32Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ttllyy](https://avatars.discourse-cdn.com/v4/letter/t/e8c25b/32.png) [@ttllyy](https://forum.mattermost.com/u/ttllyy)\
**Post date:** [April 19, 2016, 5:29pm UTC](https://forum.mattermost.com/t/whether-support-code-c-c-java-js-syntax-highlighting-in-future/1347/1 "2016-04-19T17:29:32Z")

</div>

Aflter upload a code file, support open or preview the file and code(C/C++,java,js…) syntax highlightingy.  
Or send some code snippet message, support code(C/C++,java,js…) syntax highlightingy.

---

<div class="post-metadata">

**Author:** ![hmhealey](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mattermost.com/hmhealey/32/1915_2.png) [@hmhealey](https://forum.mattermost.com/u/hmhealey)\
**Post date:** [April 21, 2016, 1:01pm UTC](https://forum.mattermost.com/t/whether-support-code-c-c-java-js-syntax-highlighting-in-future/1347/2 "2016-04-21T13:01:05Z")

</div>

Hi ttllyy,

To post code as part of a message, you can use markdown’s code block. If you specify a language after the inital ```, it’ll provide syntax highlighting it as well. For example,

````
``` javascript
function foo() {
    console.log('bar');
}
```

````

will show up as  
 ![](https://cdck-file-uploads-us1.s3.dualstack.us-west-2.amazonaws.com/flex020/uploads/mattermost/original/1X/ad906e45c4841f71a499aa2b016ace43813c28c4.png)

Also, we actually had a community member that implemented previews for uploaded code files for our next release in May so you’ll be able to use that soon.  
 ![](https://cdck-file-uploads-us1.s3.dualstack.us-west-2.amazonaws.com/flex020/uploads/mattermost/original/1X/2dbb90910051e15e1b251f096b3538c459e95e88.png)
