Socket
Socket
Sign inDemoInstall

json-schema-to-typescript

Package Overview
Dependencies
Maintainers
1
Versions
114
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

json-schema-to-typescript - npm Package Compare versions

Comparing version 4.5.1 to 4.5.2

5

dist/src/generator.js

@@ -116,3 +116,6 @@ "use strict";

case 'ANY': return 'any';
case 'ARRAY': return generateType(ast.params, options, indentDepth + 1) + '[]';
case 'ARRAY': return (function () {
var type = generateType(ast.params, options, indentDepth + 1);
return type.endsWith('"') ? '(' + type + ')[]' : type + '[]';
})();
case 'BOOLEAN': return 'boolean';

@@ -119,0 +122,0 @@ case 'INTERFACE': return generateInterface(ast, options, indentDepth + 1);

{
"name": "json-schema-to-typescript",
"version": "4.5.1",
"version": "4.5.2",
"description": "compile json schema to typescript typings",

@@ -17,3 +17,3 @@ "main": "dist/src/index.js",

"build:server": "tsc -d",
"clean": "rm -rf dist",
"clean": "shx rm -rf dist",
"lint": "tslint -c tslint.json src/*.ts",

@@ -68,2 +68,3 @@ "tdd": "concurrently -r -p '' -k 'npm run watch' 'npm run watch:test'",

"fast-diff": "^1.1.1",
"shx": "^0.2.2",
"table-layout": "^0.4.0",

@@ -70,0 +71,0 @@ "tsify": "^3.0.1",

@@ -139,3 +139,6 @@ import { whiteBright } from 'cli-color'

case 'ANY': return 'any'
case 'ARRAY': return generateType(ast.params, options, indentDepth + 1) + '[]'
case 'ARRAY': return (() => {
let type = generateType(ast.params, options, indentDepth + 1)
return type.endsWith('"') ? '(' + type + ')[]' : type + '[]'
})()
case 'BOOLEAN': return 'boolean'

@@ -142,0 +145,0 @@ case 'INTERFACE': return generateInterface(ast, options, indentDepth + 1)

dist/bundle.js

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