rs-module-lexer icon indicating copy to clipboard operation
rs-module-lexer copied to clipboard

Support type imports

Open thepassle opened this issue 2 months ago • 0 comments

Clear and concise description of the problem

Considering that:

es-module-lexer cannot parse jsx / ts / tsx files, we need transform ts to js using esbuild / swc first, and then parse :

And rs-module-lexer aims to work with ts/tsx files, I would have expected it would also handle type imports, e.g.:

import type { Foo } from './foo.ts';

Is this something that would be considered to be added in the future?

Suggested solution

Alternative

No response

Additional context

No response

Validations

  • [x] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.

thepassle avatar Oct 13 '25 09:10 thepassle