microsoft / microsoft/TypeScript
Change quick fix JSDoc Import
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 111k
- Forks
- 14.3k
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 117
Description
When adding a JSDoc comment within a .js file, such as /** @type {Entity} */, using the quick fix feature will promptly import the Entity module using the standard ECMAScript Module (ESM) syntax. However, I recommend that, when within the JSDoc comment, the import be handled using the newly released @import statement for better compatibility and clarity.
Example:
Will result in:
Result that would be nice:
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Locate the quick fix that adds imports for types referenced in JSDoc comments in JavaScript files, then compare its current ESM output with the requested JSDoc @import form. Done means the quick fix produces the requested @import statement while preserving the existing type resolution behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, typescript
- Domain
- developer-experience, tooling
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100