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

@volar/code-gen

Package Overview
Dependencies
Maintainers
1
Versions
168
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@volar/code-gen - npm Package Compare versions

Comparing version 0.37.4 to 0.37.5

6

out/index.d.ts

@@ -1,2 +0,2 @@

import type { Mapping, Mode, Range } from '@volar/source-map';
import { Mapping, Mode, Range } from '@volar/source-map';
export declare class CodeGen<T = undefined> {

@@ -11,2 +11,6 @@ private text;

};
addCode2(str: string, sourceOffset: number, data: T): {
start: number;
end: number;
};
addMapping(str: string, sourceRange: Range, mode: Mode, data: T): {

@@ -13,0 +17,0 @@ start: number;

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.mergeCodeGen = exports.CodeGen = void 0;
const source_map_1 = require("@volar/source-map");
class CodeGen {

@@ -35,2 +36,15 @@ constructor() {

}
addCode2(str, sourceOffset, data) {
const targetRange = this.addText(str);
this.addMapping2({
mappedRange: targetRange,
sourceRange: {
start: sourceOffset,
end: sourceOffset + str.length,
},
mode: source_map_1.Mode.Offset,
data,
});
return targetRange;
}
addMapping(str, sourceRange, mode, data) {

@@ -37,0 +51,0 @@ const targetRange = {

6

package.json
{
"name": "@volar/code-gen",
"version": "0.37.4",
"version": "0.37.5",
"main": "out/index.js",

@@ -16,5 +16,5 @@ "license": "MIT",

"dependencies": {
"@volar/source-map": "0.37.4"
"@volar/source-map": "0.37.5"
},
"gitHead": "ff43db17137f334dc1664b6a3285bc2e5ebcd9db"
"gitHead": "8f24dd22d7ae476f380548706853f40de8c71b7b"
}
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