-
Notifications
You must be signed in to change notification settings - Fork 12.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Reprioritize cross-project module specifier suggestions for auto-impo…
…rt (#40253) * Add test * Suggest `paths` module specifiers even when a node_modules path was available * Fix some tests * Fix remaining tests * Add comments
- Loading branch information
1 parent
db5f519
commit 8ffb7f0
Showing
11 changed files
with
444 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 43 additions & 0 deletions
43
tests/cases/fourslash/server/autoImportCrossProject_paths_sharedOutDir.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
/// <reference path="../fourslash.ts" /> | ||
|
||
// @Filename: /tsconfig.base.json | ||
//// { | ||
//// "compilerOptions": { | ||
//// "module": "commonjs", | ||
//// "baseUrl": ".", | ||
//// "paths": { | ||
//// "packages/*": ["./packages/*"] | ||
//// } | ||
//// } | ||
//// } | ||
|
||
// @Filename: /packages/app/tsconfig.json | ||
//// { | ||
//// "extends": "../../tsconfig.base.json", | ||
//// "compilerOptions": { "outDir": "../../dist/packages/app" }, | ||
//// "references": [{ "path": "../dep" }] | ||
//// } | ||
|
||
// @Filename: /packages/app/index.ts | ||
//// dep/**/ | ||
|
||
// @Filename: /packages/app/utils.ts | ||
//// import "packages/dep"; | ||
|
||
|
||
// @Filename: /packages/dep/tsconfig.json | ||
//// { | ||
//// "extends": "../../tsconfig.base.json", | ||
//// "compilerOptions": { "outDir": "../../dist/packages/dep" } | ||
//// } | ||
|
||
// @Filename: /packages/dep/index.ts | ||
//// import "./sub/folder"; | ||
|
||
// @Filename: /packages/dep/sub/folder/index.ts | ||
//// export const dep = 0; | ||
|
||
goTo.marker(""); | ||
verify.importFixAtPosition([`import { dep } from "packages/dep/sub/folder";\r | ||
\r | ||
dep`]); |
Oops, something went wrong.