Skip to content

vite.clearScreen: false option is ignorred #4468

Closed
@maxpatiiuk

Description

Describe the bug

VitePress ignores the vite.clearScreen: false option - running vitepress build will clear the screen regardless.

This is causing issues in our turbo build monorepo - when building several packages at once, VitePress's clear screen clears the log output for packages that were built before it.

Reproduction

https://stackblitz.com/edit/vite-dtu41vnr?file=package.json

  1. Install dependencies
  2. Run npx vitepress build docs
  3. See that screen is cleared, despite vite.clearScreen:false in docs/.vitepress/config.ts

Expected behavior

Screen should not be cleared if vite.clearScreen:false is set

System Info

System:
    OS: macOS 15.2
    CPU: (10) arm64 Apple M1 Pro
    Memory: 78.41 MB / 32.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 22.12.0 - ~/.local/state/fnm_multishells/64248_1736184870871/bin/node
    Yarn: 1.22.19 - ~/.local/state/fnm_multishells/64248_1736184870871/bin/yarn
    npm: 10.9.0 - ~/.local/state/fnm_multishells/64248_1736184870871/bin/npm
  Browsers:
    Chrome: 131.0.6778.205
    Safari: 18.2
  npmPackages:
    vitepress: 1.5.0 => 1.5.0

Additional context

No response

Validations

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions