Skip to content

Conversation

jakebailey
Copy link
Member

Fixes #1367

This should be a faithful port.

@Copilot Copilot AI review requested due to automatic review settings August 8, 2025 04:21
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR reimplements the rootDirs compiler option functionality, which allows TypeScript to resolve modules across multiple root directories as if they were merged into a single virtual directory structure.

Key Changes

  • Removes the rootDirs option from the unsupported features list in compiler tests
  • Implements tryLoadModuleUsingRootDirs() method for module resolution logic
  • Updates module resolution flow to attempt rootDirs resolution for relative imports after paths resolution

Reviewed Changes

Copilot reviewed 18 out of 18 changed files in this pull request and generated no comments.

File Description
internal/testrunner/compiler_runner.go Removes rootDirs from unsupported options list to enable testing
internal/module/resolver.go Implements rootDirs module resolution logic and integrates it into the resolution chain
Multiple baseline files Test output changes showing improved module resolution with rootDirs functionality

@jakebailey jakebailey added this pull request to the merge queue Aug 8, 2025
Merged via the queue into main with commit e087a3e Aug 8, 2025
22 checks passed
@jakebailey jakebailey deleted the jabaile/rootDirs branch August 8, 2025 21:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

issue with importing type from virtual directory (rootDirs)

2 participants