Skip to content

Suggest relative paths when showing 'add missing import' code action #15888

@AdamWillden

Description

@AdamWillden

The code action for adding missing imports currently provides a list of possible matches, but all seem to use absolute paths :

image

This will not work for my packages. I would like an additional option which uses a relative path from the current file (i.e. import { TreeNodeBase } from './tree-node-base';)


I'm sure this request must be somewhere in the 2000+ issues but multiple keyword searches has failed to return a result.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Domain: LS: Quick FixesEditor-provided fixes, often called code actions.FixedA PR has been merged for this issueSuggestionAn idea for TypeScript

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions