Have CompletionEntryDetails source use a relative path (#19917)

* Have CompletionEntryDetails source use a relative path

* Use getCanonicalFileName from services Instead of creating a new one
This commit is contained in:
Andy
2017-11-14 14:26:49 -08:00
committed by GitHub
parent 9c51a8534e
commit 592ee00906
24 changed files with 97 additions and 49 deletions

View File

@@ -20,7 +20,7 @@ namespace ts {
}
/* @internal */
export function computeCommonSourceDirectoryOfFilenames(fileNames: string[], currentDirectory: string, getCanonicalFileName: (fileName: string) => string): string {
export function computeCommonSourceDirectoryOfFilenames(fileNames: string[], currentDirectory: string, getCanonicalFileName: GetCanonicalFileName): string {
let commonPathComponents: string[];
const failed = forEach(fileNames, sourceFile => {
// Each file contributes into common source file path