json-schema-to-typescript
Advanced tools
Comparing version 4.5.1 to 4.5.2
@@ -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) |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1283265
37028
15