-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Open
Labels
Description
Describe the bug
When creating a new Slidev project using pnpm create slidev and attempting to start the dev server, the application fails to start with a module import error. The error indicates that twoslash-vue@0.3.4 is trying to import writeGlobalTypes from @vue/language-core, but this export does not exist in the installed version of @vue/language-core.
Minimal reproduction
Steps to reproduce the behavior:
- Run
pnpm create slidev - Enter project name (e.g., "pitch-deck")
- When prompted to remove existing files, select "yes"
- When prompted to install and start, select "yes"
- Choose
pnpmas the package manager - The dev server fails to start with the error below
You can use https://sli.dev/new to create a new project to reproduce the issue.
Error Details
file:///Users/kejvidoko/dev/byte-vision/pitch-deck/node_modules/.pnpm/twoslash-vue@0.3.4_typescript@5.9.3/node_modules/twoslash-vue/dist/index.mjs:1
import { defaultMapperFactory, CompilerOptionsResolver, writeGlobalTypes, createVueLanguagePlugin, createLanguage, FileMap } from '@vue/language-core';
^^^^^^^^^^^^^^^^
SyntaxError: The requested module '@vue/language-core' does not provide an export named 'writeGlobalTypes'
at #asyncInstantiate (node:internal/modules/esm/module_job:302:21)
at process.processTicksAndRejections (node:internal/process/task_queues:103:5)
at async ModuleJob.run (node:internal/modules/esm/module_job:405:5)
at async onImport.tracePromise.__proto__ (node:internal/modules/esm/loader:654:26)
at async Promise.all (index 2)
at async getTwoslashTransformer (file:///Users/kejvidoko/dev/byte-vision/pitch-deck/node_modules/.pnpm/@slidev+cli@52.11.1_@babel+parser@7.28.5_@nuxt+kit@3.20.2_@types+markdown-it@14.1.2_@ty_2d3842277e856cbbfece37ba94ab0f42/node_modules/@slidev/cli/dist/shared-DgnE1q2H.mjs:1734:41)
at async MarkdownItShiki (file:///Users/kejvidoko/dev/byte-vision/pitch-deck/node_modules/.pnpm/@slidev+cli@52.11.1_@babel+parser@7.28.5_@nuxt+kit@3.20.2_@types+markdown-it@14.1.2_@ty_2d3842277e856cbbfece37ba94ab0f42/node_modules/@slidev/cli/dist/shared-DgnE1q2H.mjs:1752:61)
at async useMarkdownItPlugins (file:///Users/kejvidoko/dev/byte-vision/pitch-deck/node_modules/.pnpm/@slidev+cli@52.11.1_@babel+parser@7.28.5_@nuxt+kit@3.20.2_@types+markdown-it@14.1.2_@ty_2d3842277e856cbbfece37ba94ab0f42/node_modules/@slidev/cli/dist/shared-DgnE1q2H.mjs:1832:45)
at async Object.markdownItSetup (file:///Users/kejvidoko/dev/byte-vision/pitch-deck/node_modules/.pnpm/@slidev+cli@52.11.1_@babel+parser@7.28.5_@nuxt+kit@3.20.2_@types+markdown-it@14.1.2_@ty_2d3842277e856cbbfece37ba94ab0f42/node_modules/@slidev/cli/dist/shared-DgnE1q2H.mjs:2225:4)
at async file:///Users/kejvidoko/dev/byte-vision/pitch-deck/node_modules/.pnpm/unplugin-vue-markdown@29.2.0_vite@7.3.0_@types+node@22.19.3_jiti@2.6.1_yaml@2.8.2_/node_modules/unplugin-vue-markdown/dist/chunk-WO5APWOV.js:142:5
Node.js v25.2.1
ELIFECYCLE Command failed with exit code 1.
The error originates from:
twoslash-vue@0.3.4attempting to importwriteGlobalTypesfrom@vue/language-core- The import statement:
import { defaultMapperFactory, CompilerOptionsResolver, writeGlobalTypes, createVueLanguagePlugin, createLanguage, FileMap } from '@vue/language-core';
Environment
- Slidev version:
@slidev/cli@52.11.1 - Node.js version:
v25.2.1 - Package manager:
pnpm v10.22.0 - OS: macOS (darwin 25.2.0)
- Browser: N/A (error occurs before server starts)
Additional Context
- This is a fresh project created using the Slidev CLI
- The project uses the default
seriphtheme - The error occurs during the module initialization phase, before the dev server can start
- This appears to be a dependency compatibility issue between
twoslash-vue@0.3.4and the resolved version of@vue/language-core
If you are using Slidev globally (i.e. npx slidev or npm i -g slidev), please try to reproduce the issue in a local project (i.e. npm create slidev@latest).