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

ts-string-extractor

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ts-string-extractor - npm Package Compare versions

Comparing version

to
1.0.1

dist/list.js

11

dist/find-function-calls.js

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

}
return keys;
return uniqSorted(keys);
}

@@ -62,3 +62,3 @@ function subKeysFromObjectLiteral(node) {

for (const prop of node.properties) {
if (typescript_1.default.isPropertyAssignment(prop)) {
if (typescript_1.default.isPropertyAssignment(prop) || typescript_1.default.isShorthandPropertyAssignment(prop)) {
if (typescript_1.default.isIdentifier(prop.name) || typescript_1.default.isStringLiteral(prop.name)) {

@@ -70,3 +70,3 @@ keys.push(prop.name.text);

}
return keys;
return uniqSorted(keys);
}

@@ -76,1 +76,6 @@ function listsEqualUnordered(a, b) {

}
function uniqSorted(list) {
list = [...new Set(list)];
list.sort();
return list;
}
{
"name": "ts-string-extractor",
"version": "1.0.0",
"version": "1.0.1",
"description": "Extracts the string literal contents of TypeScript function calls",

@@ -31,2 +31,3 @@ "main": "dist/index.js",

"devDependencies": {
"@types/node": "18.15.11",
"prettier": "2.8.7",

@@ -33,0 +34,0 @@ "typescript": "5.0.4"