Skip to content

Instantly share code, notes, and snippets.

@KyleMit
Last active June 9, 2021 03:36
Code Blocks & Syntax Highlighting

Trying to get syntax highlighting for indented and html based code blocks. It seems only fenced code blocks have syntax highlighting applied

Related to: How to add syntax highlighting to indented code blocks using github flavored markdown

Input:

```js
var user = "string"
```

Output:

var user = "string"

Input:

     var user = "string"

Output:

var user = "string"

Input:

<pre lang="javascript"><code>var user = <i>"string"</i>
</code></pre>

Output:

var user = "string"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment