vite-plugin-checker
vite-plugin-checker copied to clipboard
checker clears terminal on first load
Describe the bug
When enabling the checker plugin it clears the terminal, hiding the vite serve information.
Reproduction
import { defineConfig } from 'vite';
export default defineConfig({
plugins: [
checker({
typescript: true,
}),
],
});
Expected behavior
Should not clear the terminal
System Info
System:
OS: macOS 12.7
CPU: (10) arm64 Apple M1 Pro
Memory: 4.44 GB / 32.00 GB
Shell: 5.8.1 - /bin/zsh
Binaries:
Node: 20.2.0 - ~/.volta/tools/image/node/20.2.0/bin/node
Yarn: 1.22.18 - ~/.volta/tools/image/yarn/1.22.18/bin/yarn
npm: 9.6.6 - ~/.volta/tools/image/node/20.2.0/bin/npm
Watchman: 2023.04.10.00 - /opt/homebrew/bin/watchman
Browsers:
Brave Browser: 114.1.52.129
Chrome: 118.0.5993.117
Edge: 118.0.2088.76
Safari: 17.0
npmPackages:
vite-plugin-checker: ^0.6.2 => 0.6.2
Additional context
No response
Validations
- [X] Read the docs.
- [X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
More to that, when there's an error and I save the file twice terminal clears
How to reproduce:
- add any typescript error to the code (e.g. reassign a constant
const error = 'test'; error = 123;) - save twice w/o changing anything
Also, very often terminal just gets cleared and becomes fully blank even though changes were made
This terminal bug makes the plugin almost entirely unusable and is the only reason why I use tsc over it
@fi3ework could you take a look?
You can add clearScreen: false, to your Vite config. This should probably be in the docs...
@cuberoot I still want vite to clear the screen, I just want to avoid this plugin from doing it a second time and moving the ts/eslint info out of the terminal.