'\r\n const target = `\u003Cdiv id=\"app\">\u003C/div>`\r\n this.shadow = this.attachShadow({ mode: 'open' })\r\n this.shadow.innerHTML = designSystemCSS + target\r\n createApp(App) // App defined elsewhere ofc\r\n .mount(this.shadow.querySelector('#app'))\r\n }\r\n}\r\n```\n\n### Describe the solution you'd like\n\nProbably just being able to set `compilerOptions.isCustomElement` somewhere would be good enough?\n\n### Describe alternatives you've considered\n\n_No response_\n\n### Additional context\n\n_No response_\n\n### Validations\n\n- [X] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\n- [X] Read the [docs](https://vitepress.vuejs.org).\n- [X] Read the [Contributing Guidelines](https://github.com/vuejs/vitepress/blob/main/.github/contributing.md).\n- [X] Check that there isn't already an issue that asks for the same feature to avoid creating a duplicate.",[],735,"Custom element support","2023-01-21T14:34:18Z","https://github.com/vuejs/vitepress/issues/735",0.73062366,{"description":2958,"labels":2959,"number":2961,"owner":2869,"repository":2870,"state":2897,"title":2962,"updated_at":2963,"url":2964,"score":2965},"### Is your feature request related to a problem? Please describe.\n\nIt would be great to be able to pass additional languages/syntaxes to shiki (specifically `*.tmLanguage.json` files, also [see the shiki documentation](https://github.com/shikijs/shiki/blob/main/docs/languages.md#supporting-your-own-languages-with-shiki)), but currently there's no way to do that.\n\n### Describe the solution you'd like\n\nNot sure about the API, but I see two options here (not necessarily mutually-exclusive!):\r\n\r\nEither allow to simply specify path to the grammar, so it would be loaded by VitePress automagically (I guess it is relatively easy to preload custom languages [here](https://github.com/vuejs/vitepress/blob/c9f04e045922a6f1e11136bd1ccc824c2e9928f1/src/node/markdown/plugins/highlight.ts)):\r\n\r\n```ts\r\nexport default {\r\n markdown: {\r\n languages: [\r\n '/path/to/tmGrammar/json',\r\n '/path/to/tmGrammar/json'\r\n ],\r\n ...\r\n }\r\n}\r\n```\r\n\r\nOr allow end users to read, parse and pass grammars manually, something like this ([this is roughly what shiki's docs suggest](https://github.com/shikijs/shiki/blob/a99c9df9818768f432a69387a4687a3344b4926e/docs/languages.md#supporting-your-own-languages-with-shiki)):\r\n\r\n```ts\r\nconst bnfPath = join(languagesDir, 'bnf.tmLanguage.json')\r\nconst bnfJson = JSON.parse(await readFile(, 'utf8'))\r\n\r\nconst bnf = {\r\n id: bnfJson.name,\r\n scopeName: bnfJson.scopeName,\r\n aliases: bnfJson.aliases,\r\n path: bnfPath\r\n}\r\n\r\nexport default {\r\n markdown: {\r\n languages: [bnf],\r\n ...\r\n }\r\n}\r\n```\r\n\r\nThe VitePress options then would look like this:\r\n\r\n```ts\r\ninterface MarkdownOptions extends MarkdownIt.Options {\r\n theme?:\r\n | IThemeRegistration\r\n | { light: IThemeRegistration; dark: IThemeRegistration }\r\n\r\n languages?:\r\n | string[]\r\n | ILanguageRegistration[]\r\n\r\n ...\r\n}\r\n```\r\n\r\nLet me know if I'm missing something, or maybe you have some thoughts/critique.\n\n### Describe alternatives you've considered\n\n_No response_\n\n### Additional context\n\nI'm migrating from custom Next.js setup to VitePress and overall it's a blast, but also it's a bit annoying to use `haskell` language for code blocks instead of `bnf` to get the code highlighted. :)\n\n### Validations\n\n- [X] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\n- [X] Read the [docs](https://vitepress.vuejs.org).\n- [X] Read the [Contributing Guidelines](https://github.com/vuejs/vitepress/blob/main/.github/contributing.md).\n- [X] Check that there isn't already an issue that asks for the same feature to avoid creating a duplicate.",[2960],{"name":2880,"color":2881},1533,"Allow to pass additional languages to shiki","2023-03-06T00:04:34Z","https://github.com/vuejs/vitepress/issues/1533",0.73349595,["Reactive",2967],{},["Set"],["ShallowReactive",2970],{"$fTRc1wZytZ_XrK4EfJfei_Sz-An4H4Yy6syhVxH_PVJc":-1,"$fMKbIEJEtZznH2RpS6rVajvRpOP2Qum-qlUDdDaOYtxE":-1},"/vuejs/vitepress/4765"]