Open taktran opened 2 months ago
I copied over the Astro Shiki extension and console logged the results when parsing a .mdoc
file, and it seems like the extension is returning the correct output, so I'm thinking it's the Astro/Markdoc wrapping around it.
.mdoc
{% if isFramework("react") %}
react code
```js
const js = "hello";
{% /if %}
Inside the shiki extension
console.log({ lang, content: attributes.content, html, unescaped: unescapeHTML(html), });
Console
{ lang: 'js', content: 'const js = "hello";\n', html: '
const js = "hello";\n' +
'
',
unescaped: [String (HTMLString): 'const js = "hello";\n' +
'
']
}
Astro Info
If this issue only occurs in one browser, which browser is a problem?
No response
Describe the Bug
Using shiki code highlighting inside a markdoc
if
tag results in nothing being rendered (including other content inside theif
tag).What's the expected result?
In this
.mdoc
file:{% /if %}