Skip to content

feat: [P2][resolver] Follow import paths (relative + tsconfig paths aliases) #73

Description

@codeakki

Problem

The resolver is name-based: import { foo } from './bar' is not followed. When foo exists in several files it picks same-file-first then first-global-match — which can be wrong. This is the single biggest accuracy lever (see docs/limitations.md § Resolver accuracy).

Proposal

Follow import paths during edge resolution:

  • relative specifiers (./bar, ../x), with index.ts directory conventions
  • tsconfig.json paths aliases (read the file directly — no compiler API, no child_process)

Out of scope here (separate issues): re-export chains (#TBD), scope-aware binding (#TBD), type-based method dispatch (deferred).

Acceptance

  • Relative + index + tsconfig-alias imports resolve to the correct in-repo symbol
  • Measured precision on the bench/resolver/ corpus improves vs baseline
  • No network / no child_process

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions