shikijs / shiki

A beautiful yet powerful syntax highlighter
http://shiki.style/
MIT License
9.19k stars 330 forks source link

Describe the bug here #708

Closed 321paranoiawhy closed 1 week ago

321paranoiawhy commented 1 week ago

Validations

Describe the bug

Such code in vitepress:

```vue twoslash :line-numbers
<script setup lang="ts">
import {ref} from 'vue';

const message = ref('Hello world!');
</script>


code block line numbers would be from 1 to 2, rather than from 1 to 5, [see here](https://321paranoiawhy.github.io/knowledge-base/TODO#bug)

### Reproduction

````md ```vue twoslash :line-numbers <script setup lang="ts"> import {ref} from 'vue';  const message = ref('Hello world!'); </script> ``` ````

### Contributes

- [ ] I am willing to submit a PR to fix this issue
- [ ] I am willing to submit a PR with failing tests
321paranoiawhy commented 1 week ago

I have already open an issue in vitepress.

This is current behavior:

antfu commented 1 week ago

We temporarily closed this due to the lack of enough information. We could not identify whether it was a bug or a userland misconfiguration with the given info. Please provide a minimal reproduction to reopen the issue. Thanks.

Why reproduction is required