-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Vite-node uses undeclared export vite/types/hot
#3704
Labels
Comments
|
My temporary workaround using patch-package: diff --git a/node_modules/vite-node/dist/server.d.ts b/node_modules/vite-node/dist/server.d.ts
index a21e596..80b6bd2 100644
--- a/node_modules/vite-node/dist/server.d.ts
+++ b/node_modules/vite-node/dist/server.d.ts
@@ -1,3 +1,4 @@
+//@ts-expect-error
import { TransformResult, ViteDevServer } from 'vite';
import { E as EncodedSourceMap } from './types.d-7442d07f.js';
import { g as DebuggerOptions, D as DepsHandlingOptions, f as ViteNodeServerOptions, F as FetchResult, e as ViteNodeResolveId } from './types-e8623e9c.js';
diff --git a/node_modules/vite-node/dist/types-e8623e9c.d.ts b/node_modules/vite-node/dist/types-e8623e9c.d.ts
index dfe926f..ac99fe8 100644
--- a/node_modules/vite-node/dist/types-e8623e9c.d.ts
+++ b/node_modules/vite-node/dist/types-e8623e9c.d.ts
@@ -1,3 +1,4 @@
+//@ts-expect-error
import { ViteHotContext } from 'vite/types/hot';
import { E as EncodedSourceMap } from './types.d-7442d07f.js';
|
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Describe the bug
This line uses an undeclared export:
vitest/packages/vite-node/src/types.ts
Line 1 in a96bc22
When running typescript with
"moduleResolution": "bundler"
, it fails compilation with undeclared exports.The allowed vite exports can be found here: https://github.com/vitejs/vite/blob/126e93e6693474a038a5053b7cefb99295f21eb5/packages/vite/package.json#L21-L32
Reproduction
https://stackblitz.com/edit/vitest-dev-vitest-spzqkv?file=package.json,tsconfig.json&initialPath=__vitest__/
System Info
Used Package Manager
npm
Validations
The text was updated successfully, but these errors were encountered: