forked from microsoft/TypeScript
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Interactive inlay hints] Get source file from parameter node (micros…
- Loading branch information
1 parent
4c7eb39
commit 443123b
Showing
4 changed files
with
68 additions
and
15 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
21 changes: 21 additions & 0 deletions
21
tests/baselines/reference/inlayHintsInteractiveMultifileFunctionCalls.baseline
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,21 @@ | ||
helperB("hello, world!"); | ||
^ | ||
{ | ||
"text": "", | ||
"position": 45, | ||
"kind": "Parameter", | ||
"whitespaceAfter": true, | ||
"displayParts": [ | ||
{ | ||
"text": "bParam", | ||
"span": { | ||
"start": 61, | ||
"length": 6 | ||
}, | ||
"file": "/tests/cases/fourslash/bbb.mts" | ||
}, | ||
{ | ||
"text": ":" | ||
} | ||
] | ||
} |
24 changes: 24 additions & 0 deletions
24
tests/cases/fourslash/inlayHintsInteractiveMultifileFunctionCalls.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,24 @@ | ||
/// <reference path="fourslash.ts" /> | ||
|
||
// @Target: esnext | ||
// @module: nodenext | ||
|
||
// @Filename: aaa.mts | ||
////import { helperB } from "./bbb.mjs"; | ||
////helperB("hello, world!"); | ||
|
||
// @Filename: bbb.mts | ||
////import { helperC } from "./ccc.mjs"; | ||
|
||
////export function helperB(bParam: string) { | ||
//// helperC(bParam); | ||
////} | ||
|
||
// @Filename: ccc.mts | ||
////export function helperC(cParam: string) {} | ||
|
||
goTo.file("./aaa.mts"); | ||
verify.baselineInlayHints(undefined, { | ||
includeInlayParameterNameHints: "all", | ||
interactiveInlayHints: true | ||
}); |