New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

kecubung

Package Overview
Dependencies
Maintainers
1
Versions
67
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

kecubung - npm Package Compare versions

Comparing version 0.0.7-1 to 0.0.7-2

4

lib/dts/analyzers/astree/es6-class-analyzer.d.ts

@@ -9,4 +9,8 @@ import { ClassAnalyzer } from "./class-analyzer";

getName(): any;
private isClass();
private isVariableDeclaration();
isCandidate(): boolean;
private getBaseClassSimple();
private getBaseClassWithDeclaration();
getBaseClass(): any;
}

@@ -16,11 +16,25 @@ "use strict";

Es6ClassAnalyzer.prototype.getMember = function () {
return this.node.body.body;
if (this.isClass())
return this.node.body.body;
else
return this.node.declarations[0].init.body.body;
};
Es6ClassAnalyzer.prototype.getName = function () {
return this.node.id.name;
if (this.isClass())
return this.node.id.name;
else
return this.node.declarations[0].init.id.name;
};
Es6ClassAnalyzer.prototype.isCandidate = function () {
Es6ClassAnalyzer.prototype.isClass = function () {
return this.node.type == core_1.SyntaxKind.ClassDeclaration;
};
Es6ClassAnalyzer.prototype.getBaseClass = function () {
Es6ClassAnalyzer.prototype.isVariableDeclaration = function () {
return this.node.type == core_1.SyntaxKind.VariableDeclaration &&
this.node.declarations[0].init &&
this.node.declarations[0].init.type == core_1.SyntaxKind.ClassExpression;
};
Es6ClassAnalyzer.prototype.isCandidate = function () {
return this.isClass() || this.isVariableDeclaration();
};
Es6ClassAnalyzer.prototype.getBaseClassSimple = function () {
if (!this.node.superClass)

@@ -33,4 +47,18 @@ return;

};
Es6ClassAnalyzer.prototype.getBaseClassWithDeclaration = function () {
if (!this.node.declarations[0].init.superClass)
return;
if (this.node.declarations[0].init.superClass.type == core_1.SyntaxKind.MemberExpression)
return this.node.declarations[0].init.superClass.property.name;
else
return this.node.declarations[0].init.superClass.name;
};
Es6ClassAnalyzer.prototype.getBaseClass = function () {
if (this.isClass())
return this.getBaseClassSimple();
else
return this.getBaseClassWithDeclaration();
};
return Es6ClassAnalyzer;
}(class_analyzer_1.ClassAnalyzer));
exports.Es6ClassAnalyzer = Es6ClassAnalyzer;

2

package.json
{
"name": "kecubung",
"version": "0.0.7-1",
"version": "0.0.7-2",
"description": "Javascript transformer to Type Metadata",

@@ -5,0 +5,0 @@ "main": "./lib/source/index.js",

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