Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@volar/typescript

Package Overview
Dependencies
Maintainers
0
Versions
222
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@volar/typescript - npm Package Compare versions

Comparing version 2.4.0-alpha.1 to 2.4.0-alpha.2

3

lib/protocol/createProject.d.ts
import { Language } from '@volar/language-core';
import type * as ts from 'typescript';
import { URI } from 'vscode-uri';
import type { TypeScriptExtraServiceScript } from '../..';

@@ -8,5 +7,5 @@ import type { createSys } from './createSys';

}
export declare function createLanguageServiceHost(ts: typeof import('typescript'), sys: ReturnType<typeof createSys> | ts.System, language: Language<URI>, asUri: (fileName: string) => URI, projectHost: TypeScriptProjectHost): {
export declare function createLanguageServiceHost<T>(ts: typeof import('typescript'), sys: ReturnType<typeof createSys> | ts.System, language: Language<T>, asScriptId: (fileName: string) => T, projectHost: TypeScriptProjectHost): {
languageServiceHost: ts.LanguageServiceHost;
getExtraServiceScript: (fileName: string) => TypeScriptExtraServiceScript | undefined;
};

@@ -7,3 +7,3 @@ "use strict";

const resolveModuleName_1 = require("../resolveModuleName");
function createLanguageServiceHost(ts, sys, language, asUri, projectHost) {
function createLanguageServiceHost(ts, sys, language, asScriptId, projectHost) {
const scriptVersions = new language_core_1.FileMap(sys.useCaseSensitiveFileNames);

@@ -86,3 +86,3 @@ let lastProjectVersion;

}
const sourceScript = language.scripts.get(asUri(fileName));
const sourceScript = language.scripts.get(asScriptId(fileName));
if (sourceScript?.generated) {

@@ -124,3 +124,3 @@ const serviceScript = sourceScript.generated.languagePlugin.typescript?.getServiceScript(sourceScript.generated.root);

const moduleCache = ts.createModuleResolutionCache(languageServiceHost.getCurrentDirectory(), languageServiceHost.useCaseSensitiveFileNames?.() ? s => s : s => s.toLowerCase(), languageServiceHost.getCompilationSettings());
const resolveModuleName = (0, resolveModuleName_1.createResolveModuleName)(ts, languageServiceHost, language.plugins, fileName => language.scripts.get(asUri(fileName)));
const resolveModuleName = (0, resolveModuleName_1.createResolveModuleName)(ts, languageServiceHost, language.plugins, fileName => language.scripts.get(asScriptId(fileName)));
let lastSysVersion = 'version' in sys ? sys.version : undefined;

@@ -166,3 +166,3 @@ languageServiceHost.resolveModuleNameLiterals = (moduleLiterals, containingFile, redirectedReference, options, sourceFile) => {

for (const fileName of projectHost.getScriptFileNames()) {
const sourceScript = language.scripts.get(asUri(fileName));
const sourceScript = language.scripts.get(asScriptId(fileName));
if (sourceScript?.generated) {

@@ -206,3 +206,3 @@ const serviceScript = sourceScript.generated.languagePlugin.typescript?.getServiceScript(sourceScript.generated.root);

}
const sourceScript = language.scripts.get(asUri(fileName));
const sourceScript = language.scripts.get(asScriptId(fileName));
if (sourceScript?.generated) {

@@ -231,3 +231,3 @@ const serviceScript = sourceScript.generated.languagePlugin.typescript?.getServiceScript(sourceScript.generated.root);

}
const sourceScript = language.scripts.get(asUri(fileName));
const sourceScript = language.scripts.get(asScriptId(fileName));
if (sourceScript?.generated) {

@@ -244,3 +244,3 @@ const serviceScript = sourceScript.generated.languagePlugin.typescript?.getServiceScript(sourceScript.generated.root);

if (isOpenedFile) {
const sourceScript = language.scripts.get(asUri(fileName));
const sourceScript = language.scripts.get(asScriptId(fileName));
if (sourceScript && !sourceScript.generated) {

@@ -247,0 +247,0 @@ if (!version.map.has(sourceScript.snapshot)) {

{
"name": "@volar/typescript",
"version": "2.4.0-alpha.1",
"version": "2.4.0-alpha.2",
"license": "MIT",

@@ -15,3 +15,3 @@ "files": [

"dependencies": {
"@volar/language-core": "2.4.0-alpha.1",
"@volar/language-core": "2.4.0-alpha.2",
"path-browserify": "^1.0.1",

@@ -23,5 +23,5 @@ "vscode-uri": "^3.0.8"

"@types/path-browserify": "latest",
"@volar/language-service": "2.4.0-alpha.1"
"@volar/language-service": "2.4.0-alpha.2"
},
"gitHead": "c096c457fea026fcd432b82224026f747fab571b"
"gitHead": "62914047f925b79391fee6e4f697705b77641baf"
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc