replace whole path if directory separator appears for import completion. (#41412)

* replace whole path if directory separator appears.

* Fix.

* revert change.

* Fix test case.

* add test.

* fix as suggested.

* revert useless change

* adapt to code change.

* fix baseline for test file.
This commit is contained in:
Song Gao
2020-11-26 01:37:08 +08:00
committed by GitHub
parent 242e0202cf
commit d5779c75d3
4 changed files with 111 additions and 4 deletions

View File

@@ -6,7 +6,7 @@ namespace ts {
* we expect the host to correctly handle paths in our specified format.
*/
export const directorySeparator = "/";
const altDirectorySeparator = "\\";
export const altDirectorySeparator = "\\";
const urlSchemeSeparator = "://";
const backslashRegExp = /\\/g;