You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was investigating why node types are included in my project and came to cause being .wxt/types/imports.d.ts file, which imports for example: const ContentScriptContext: typeof import('wxt/client')['ContentScriptContext']
And that file uses:
import { ContentScriptDefinition } from '../../types'
Which in turn imports: import type * as vite from 'vite';
If we look at vite, it uses <reference types="node" /> which means any file importing it also gets the same types.
The fix would be split vite types from client ones, so two are not mixed.
Reproduction
n/a
Steps to reproduce
Try using const timeout: number = setTimeout(() => {})
Describe the bug
See the same issue in different package Anber/wyw-in-js#33
I was investigating why node types are included in my project and came to cause being
.wxt/types/imports.d.ts
file, which imports for example:const ContentScriptContext: typeof import('wxt/client')['ContentScriptContext']
And that file uses:
import { ContentScriptDefinition } from '../../types'
Which in turn imports:
import type * as vite from 'vite';
If we look at vite, it uses
<reference types="node" />
which means any file importing it also gets the same types.The fix would be split vite types from client ones, so two are not mixed.
Reproduction
n/a
Steps to reproduce
Try using
const timeout: number = setTimeout(() => {})
System Info
Used Package Manager
pnpm
Validations
The text was updated successfully, but these errors were encountered: