Plugs tsc --watch into Vite dev server
npm install vite-plugin-tsc-watchPlugs tsc --watch into Vite dev server. Like @nabla/vite-plugin-eslint this is a dev-only low noise plugin. It will just add logs to the dev server and not trigger an overlay while you're debugging or iterating on your code.
``sh`
npm i -D vite-plugin-tsc-watch
`ts
import { defineConfig } from "vite";
import { tscWatch } from "vite-plugin-tsc-watch";
export default defineConfig({
plugins: [tscWatch()],
});
`
To ensure .ts and .tsx files are not needlessly transpiled to .js files littering your codebase, set compilerOptions.noEmit: true in your tsconfig.json`.