#1272·shiki

Transformers not work with rose-pine theme and some langs like bash, yaml...

Author: augustanationalCreated Apr 29, 2026Updated Apr 29, 2026

Validations

Describe the bug

I think it similer to https://github.com/shikijs/shiki/issues/1083 and https://github.com/shikijs/shiki/pull/1118. But https://github.com/shikijs/shiki/pull/1118 only solved comment begin with //, so it only work with javascript, typescript ... With lang have comment begin with # like yaml, bash ... transformers not work with rose-pine theme.

Reproduction

xml
<div id="foo"></div>

<script type="module">

import {
  transformerNotationDiff,
  // ...
} from 'https://esm.sh/@shikijs/transformers'
import { codeToHtml } from 'https://esm.sh/shiki'

const foo = document.getElementById('foo')
foo.innerHTML = await codeToHtml('foo # [!code ++]', {
  lang: 'yaml',
  theme: 'rose-pine-dawn',
  transformers: [
    transformerNotationDiff(), 
    // ...
  ],
})

</script>
Image

Contributes

  • I am willing to submit a PR to fix this issue
  • I am willing to submit a PR with failing tests