-
-
Notifications
You must be signed in to change notification settings - Fork 219
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Clear and concise description of the problem
AutoImport({
dirs: ['./components'],
})
This will generate an auto-imports.d.ts
like this:
// ...
declare global {
// ...
const Comp: typeof import('./components/Comp')['Comp']
// ...
}
// ...
Deno does not like this syntax and will throw an error like this:
Unable to load a local module: file:///path/to/project/components/Comp
Maybe add a '.tsx' extension. deno(no-local)
It will be useful to allow users preserving the file extensions to solve this problem. Final output will be like this:
// ...
declare global {
// ...
const Comp: typeof import('./components/Comp.tsx')['Comp']
// ...
}
// ...
Suggested solution
Add an option to preserve file extensions in generated auto-imports.d.ts
Alternative
No response
Additional context
deno 2.5.3
unplugin-auto-import 20.2.0
vite 7.1.9
Validations
- Follow our Code of Conduct
- Read the Contributing Guide.
- Check that there isn't already an issue that request the same feature to avoid creating a duplicate.
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request