Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[bug] An error occurred deploying Vitepress Project #11127

Closed
chenmingyong0423 opened this issue Feb 6, 2024 · 0 comments
Closed

[bug] An error occurred deploying Vitepress Project #11127

chenmingyong0423 opened this issue Feb 6, 2024 · 0 comments

Comments

@chenmingyong0423
Copy link

There was no problem with the deployment before, but a problem was found when I deployed vitepress project today.

package.json:

{
  "scripts": {
    "docs:dev": "vitepress dev docs",
    "docs:build": "vitepress build docs",
    "docs:preview": "vitepress preview docs"
  }
}

deployment commands:

  • Build command

    npm run docs:build
    
  • Output directory

    docs/.vitepress/dist
    
  • Install command:

    npm add -D vitepress@latest
    
  • error log

    Running build in Washington, D.C., USA (East) – iad1
    22:27:09.821 | Cloning github.com/chenmingyong0423/go-mongox-doc (Branch: main, Commit: 4406d12)
    22:27:09.830 | Skipping build cache, deployment was triggered without cache.
    22:27:10.081 | Cloning completed: 259.96ms
    22:27:10.336 | Running "vercel build"
    22:27:10.825 | Vercel CLI 33.2.0
    22:27:11.515 | Running "install" command: `npm add -D vitepress@latest`...
    22:27:20.277 |  
    22:27:20.277 | added 80 packages, and audited 81 packages in 8s
    22:27:20.278 |  
    22:27:20.278 | 10 packages are looking for funding
    22:27:20.278 | run `npm fund` for details
    22:27:20.279 |  
    22:27:20.279 | found 0 vulnerabilities
    22:27:20.592 |  
    22:27:20.592 | > docs:build
    22:27:20.592 | > vitepress build docs
    22:27:20.592 |  
    22:27:20.840 | file:///vercel/path0/node_modules/vitepress/dist/node/serve-TjCp41j0.js:32
    22:27:20.841 | import { getHighlighter, bundledLanguages, addClassToHast, isPlaintext, isSpecialLang } from 'shiki';
    22:27:20.841 | ^^^^^^^^^^^
    22:27:20.841 | SyntaxError: The requested module 'shiki' does not provide an export named 'isPlaintext'
    22:27:20.841 | at ModuleJob._instantiate (node:internal/modules/esm/module_job:124:21)
    22:27:20.841 | at async ModuleJob.run (node:internal/modules/esm/module_job:190:5)
    22:27:20.841 |  
    22:27:20.842 | Node.js v18.18.2
    22:27:20.856 | Error: Command "npm run docs:build" exited with 1
    22:27:21.011
    
    <br class="Apple-interchange-newline">
    

I also had no problem building locally.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant