We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 03b0e73 commit 23de645Copy full SHA for 23de645
src/utils/renderer.ts
@@ -174,6 +174,8 @@ export function initRenderer(opts: IOpts) {
174
const langText = lang.split(` `)[0]
175
const language = hljs.getLanguage(langText) ? langText : `plaintext`
176
let highlighted = hljs.highlight(text, { language }).value
177
+ // tab to 4 spaces
178
+ highlighted = highlighted.replace(/\t/g, ' ')
179
highlighted = highlighted
180
.replace(/\r\n/g, `<br/>`)
181
.replace(/\n/g, `<br/>`)
0 commit comments