@volar/typescript 2.4.18 → 2.4.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -13,12 +13,16 @@ function createResolveModuleName(ts, getFileSize, host, languagePlugins, getSour
13
13
  ? host.useCaseSensitiveFileNames.bind(host)
14
14
  : host.useCaseSensitiveFileNames,
15
15
  fileExists(fileName) {
16
+ const result = host.fileExists(fileName);
16
17
  for (const { typescript } of languagePlugins) {
17
18
  if (!typescript) {
18
19
  continue;
19
20
  }
20
- for (const { extension } of typescript.extraFileExtensions) {
21
- if (fileName.endsWith(`.d.${extension}.ts`)) {
21
+ if (!result) {
22
+ for (const { extension } of typescript.extraFileExtensions) {
23
+ if (!fileName.endsWith(`.d.${extension}.ts`)) {
24
+ continue;
25
+ }
22
26
  const sourceFileName = fileName.slice(0, -`.d.${extension}.ts`.length) + `.${extension}`;
23
27
  if (fileExists(sourceFileName)) {
24
28
  const sourceScript = getSourceScript(sourceFileName);
@@ -63,7 +67,7 @@ function createResolveModuleName(ts, getFileSize, host, languagePlugins, getSour
63
67
  }
64
68
  }
65
69
  }
66
- return host.fileExists(fileName);
70
+ return result;
67
71
  },
68
72
  };
69
73
  return (moduleName, containingFile, compilerOptions, cache, redirectedReference, resolutionMode) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@volar/typescript",
3
- "version": "2.4.18",
3
+ "version": "2.4.19",
4
4
  "license": "MIT",
5
5
  "files": [
6
6
  "**/*.js",
@@ -12,14 +12,14 @@
12
12
  "directory": "packages/typescript"
13
13
  },
14
14
  "dependencies": {
15
- "@volar/language-core": "2.4.18",
15
+ "@volar/language-core": "2.4.19",
16
16
  "path-browserify": "^1.0.1",
17
17
  "vscode-uri": "^3.0.8"
18
18
  },
19
19
  "devDependencies": {
20
20
  "@types/node": "latest",
21
21
  "@types/path-browserify": "latest",
22
- "@volar/language-service": "2.4.18"
22
+ "@volar/language-service": "2.4.19"
23
23
  },
24
- "gitHead": "2093bc370bcea22576f54ad2ab453b00fd1948e3"
24
+ "gitHead": "1bf8e87e3d451369e0cc3f0eb6d8ecaf2a9365f8"
25
25
  }