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

api-typescript-generator

Package Overview
Dependencies
Maintainers
0
Versions
46
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

api-typescript-generator - npm Package Compare versions

Comparing version 2.5.3 to 2.5.4

18

lib/utils/jsdoc.js

@@ -13,8 +13,15 @@ "use strict";

}
function stringifyExample(example) {
const result = JSON.stringify(example, null, 2);
if (Array.isArray(example)) {
return '```\n' + result + '\n```';
}
return result;
}
function exampleToString(example) {
if (typeof example !== 'string') {
return JSON.stringify(example, null, 4);
return stringifyExample(example);
}
try {
return JSON.stringify(JSON.parse(example), null, 2);
return stringifyExample(JSON.parse(example));
}

@@ -67,3 +74,8 @@ catch (e) {

if (value.match(/^[\n]/)) {
result += `:\n\`\`\`${value}\`\`\``;
if (value.match(/^\n```/)) {
result += `:\n${value}`;
}
else {
result += `:\n\`\`\`${value}\`\`\``;
}
}

@@ -70,0 +82,0 @@ else {

2

package.json
{
"name": "api-typescript-generator",
"version": "2.5.3",
"version": "2.5.4",
"description": "Generates OpenAPI TypeScript client. Extremely fast and flexible.",

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

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