Transform fails with Unexpected "..." #10501
Labels
bug: upstream
Bug in a dependency of Vite
p3-minor-bug
An edge case that only affects very specific usage (priority)
Describe the bug
When running
vitest
, annotating the following re-exported function with it's type:causes
vitest
to fail with the following error:The error references an
Unexpected "..."
in the type annotation (preceding the tuple parameter) even though this is perfectly valid typescript.Removing the type annotation causes tests to pass successfully:
Downstream issue for reference: vitest-dev/vitest#2157
Reproduction
https://gitpod.io/#https://github.com/fp-ts/data
Steps to reproduce
Navigate to the following GitPod url:
Add the type annotation to
tuple
in theSafeEval
module here.Run
pnpm install
followed bypnpm test
.System Info
Used Package Manager
pnpm
Logs
No response
Validations
The text was updated successfully, but these errors were encountered: