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

@volar/vue-code-gen

Package Overview
Dependencies
Maintainers
1
Versions
79
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@volar/vue-code-gen - npm Package Compare versions

Comparing version 0.34.9 to 0.34.10

4

out/parsers/scriptSetupRanges.js

@@ -24,3 +24,5 @@ "use strict";

&& !isTypeExport
&& !ts.isEmptyStatement(node)) {
&& !ts.isEmptyStatement(node)
// fix https://github.com/johnsoncodehk/volar/issues/1223
&& !ts.isImportEqualsDeclaration(node)) {
importSectionEndOffset = node.getStart(ast);

@@ -27,0 +29,0 @@ foundNonImportExportNode = true;

import type * as ts from 'typescript/lib/tsserverlibrary';
export declare function walkInterpolationFragment(ts: typeof import('typescript/lib/tsserverlibrary'), code: string, cb: (fragment: string, offset: number | undefined) => void, localVars: Record<string, number>, identifiers: Set<string>): void;
export declare function walkInterpolationFragment(ts: typeof import('typescript/lib/tsserverlibrary'), code: string, cb: (fragment: string, offset: number | undefined, beforeCtxAccess?: {
ctxText: string;
varLength: number;
}) => void, localVars: Record<string, number>, identifiers: Set<string>): void;
export declare function colletVars(ts: typeof import('typescript/lib/tsserverlibrary'), node: ts.Node, result: string[]): void;

@@ -28,2 +28,3 @@ "use strict";

// localVarOffsets = localVarOffsets.sort((a, b) => a - b);
let lastCtxAccess;
if (ctxVars.length) {

@@ -38,13 +39,15 @@ if (ctxVars[0].isShorthand) {

for (let i = 0; i < ctxVars.length - 1; i++) {
cb('__VLS_ctx.', undefined);
writeCtxAccess(ctxVars[i].text.length);
if (ctxVars[i + 1].isShorthand) {
cb(code.substring(ctxVars[i].offset, ctxVars[i + 1].offset + ctxVars[i + 1].text.length), ctxVars[i].offset);
cb(code.substring(ctxVars[i].offset, ctxVars[i + 1].offset + ctxVars[i + 1].text.length), ctxVars[i].offset, lastCtxAccess);
cb(': ', undefined);
}
else {
cb(code.substring(ctxVars[i].offset, ctxVars[i + 1].offset), ctxVars[i].offset);
cb(code.substring(ctxVars[i].offset, ctxVars[i + 1].offset), ctxVars[i].offset, lastCtxAccess);
}
lastCtxAccess = undefined;
}
cb('__VLS_ctx.', undefined);
cb(code.substring(ctxVars[ctxVars.length - 1].offset), ctxVars[ctxVars.length - 1].offset);
writeCtxAccess(ctxVars[ctxVars.length - 1].text.length);
cb(code.substring(ctxVars[ctxVars.length - 1].offset), ctxVars[ctxVars.length - 1].offset, lastCtxAccess);
lastCtxAccess = undefined;
}

@@ -54,2 +57,9 @@ else {

}
function writeCtxAccess(varLength) {
cb('__VLS_ctx.', undefined);
lastCtxAccess = {
ctxText: '__VLS_ctx.',
varLength,
};
}
}

@@ -56,0 +66,0 @@ exports.walkInterpolationFragment = walkInterpolationFragment;

{
"name": "@volar/vue-code-gen",
"version": "0.34.9",
"version": "0.34.10",
"main": "out/index.js",

@@ -19,4 +19,4 @@ "license": "MIT",

"dependencies": {
"@volar/code-gen": "0.34.9",
"@volar/source-map": "0.34.9",
"@volar/code-gen": "0.34.10",
"@volar/source-map": "0.34.10",
"@vue/compiler-core": "^3.2.31",

@@ -26,3 +26,3 @@ "@vue/compiler-dom": "^3.2.31",

},
"gitHead": "80523163eb73755da2b136be15c871e7a4c5ce6e"
"gitHead": "0c9b6df3a2cefa25bbac9a38003eae729a772dd5"
}

Sorry, the diff of this file is too big to display

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