aleclarson / vite-tsconfig-paths

Support for TypeScript's path mapping in Vite
MIT License
1.24k stars 43 forks source link

Allow other type extensions, not only `tsx` #74

Closed websolutions-hamburg closed 1 year ago

websolutions-hamburg commented 1 year ago

Hello,

this is a great plugin. We like to use it with a project, where we use *.mts files. Unfortunately, the plugin only allows the use of files with the extension *`.tsx`**: https://github.com/aleclarson/vite-tsconfig-paths/blob/8e5a382a8f03233504ca391ea4c2119ffbc746b7/src/index.ts#L110

Would it be possible to use other file extensions such as *.mts or *.ts?

aleclarson commented 1 year ago

Fixed in 3.6.0

Note: .ts files were already supported. The x is optional in that regexp.