toshiki-notebook/docs/application/vitepress-plugin-shiki-twoslash/guide/markdown-extensions.md

1.4 KiB

title
Markdown Extensions

Markdown Extensions

Code Groups

Code Groups and Twoslash multi-file support.

::: code-group

// @module: esnext
// @filename: name.ts
export const name = 'twoslash'
// @filename: index.ts
// ---cut---
import { name } from './name'
export function hello(name: string) {
    console.log(`Hello, ${name}!`)
}
hello(name)
//    ^?
export const name = 'twoslash'

:::

Unsupported Extensions

Since VitePress Twoslash uses it's own Shiki highlighter, the following syntax highlighting extensions are not currently compatible.

If you are interested in adding support, please start a new GitHub Discussion.