Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

typescript-json-schema

Package Overview
Dependencies
Maintainers
2
Versions
93
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

typescript-json-schema - npm Package Compare versions

Comparing version 0.37.0 to 0.38.0

28

package.json
{
"name": "typescript-json-schema",
"version": "0.37.0",
"version": "0.38.0",
"description": "typescript-json-schema generates JSON Schema files from your Typescript sources",

@@ -49,20 +49,20 @@ "main": "typescript-json-schema.js",

"dependencies": {
"glob": "~7.1.2",
"glob": "~7.1.4",
"json-stable-stringify": "^1.0.1",
"typescript": "^3.0.1",
"yargs": "^12.0.1"
"typescript": "^3.4.5",
"yargs": "^13.2.4"
},
"devDependencies": {
"@types/assertion-error": "^1.1.0",
"@types/chai": "^4.1.4",
"@types/glob": "^5.0.35",
"@types/chai": "^4.1.7",
"@types/glob": "^7.1.1",
"@types/json-stable-stringify": "^1.0.32",
"@types/mocha": "^5.2.5",
"@types/node": "^10.9.1",
"ajv": "^6.5.3",
"chai": "^4.1.2",
"mocha": "^5.2.0",
"source-map-support": "^0.5.9",
"ts-node": "^7.0.1",
"tslint": "^5.11.0"
"@types/mocha": "^5.2.6",
"@types/node": "^12.0.2",
"ajv": "^6.10.0",
"chai": "^4.2.0",
"mocha": "^6.1.4",
"source-map-support": "^0.5.12",
"ts-node": "^8.1.0",
"tslint": "^5.16.0"
},

@@ -69,0 +69,0 @@ "scripts": {

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

}
else if (flags & ts.TypeFlags.Any) {
else if ((flags & ts.TypeFlags.Any) || (flags & ts.TypeFlags.Unknown)) {
}

@@ -299,3 +299,3 @@ else if (propertyTypeString === "Date" && !this.args.rejectDateType) {

if ((propertyType.flags & ts.TypeFlags.Object) &&
(propertyType.objectFlags & (ts.ObjectFlags.Anonymous | ts.ObjectFlags.Interface))) {
(propertyType.objectFlags & (ts.ObjectFlags.Anonymous | ts.ObjectFlags.Interface | ts.ObjectFlags.Mapped))) {
definition.type = "object";

@@ -725,3 +725,3 @@ definition.additionalProperties = false;

var reffedDefinition = void 0;
if (asTypeAliasRef && reffedType.getFlags() & (ts.TypeFlags.IndexedAccess | ts.TypeFlags.Index | ts.TypeFlags.Intersection) && symbol) {
if (asTypeAliasRef && reffedType && typ.symbol !== reffedType && symbol) {
reffedDefinition = this.getTypeDefinition(typ, true, undefined, symbol, symbol);

@@ -980,2 +980,3 @@ }

delete options.declaration;
delete options.declarationDir;
delete options.declarationMap;

@@ -997,4 +998,4 @@ var program = ts.createProgram({

function exec(filePattern, fullTypeName, args) {
var _a;
if (args === void 0) { args = getDefaultArgs(); }
var _a;
var program;

@@ -1001,0 +1002,0 @@ var onlyIncludeFiles = undefined;

@@ -410,3 +410,3 @@ import * as glob from "glob";

definition.type = "undefined";
} else if (flags & ts.TypeFlags.Any) {
} else if ((flags & ts.TypeFlags.Any) || (flags & ts.TypeFlags.Unknown)) {
// no type restriction, so that anything will match

@@ -427,3 +427,3 @@ } else if (propertyTypeString === "Date" && !this.args.rejectDateType) {

if ((propertyType.flags & ts.TypeFlags.Object) &&
((propertyType as ts.ObjectType).objectFlags & (ts.ObjectFlags.Anonymous | ts.ObjectFlags.Interface))) {
((propertyType as ts.ObjectType).objectFlags & (ts.ObjectFlags.Anonymous | ts.ObjectFlags.Interface | ts.ObjectFlags.Mapped))) {
definition.type = "object";

@@ -918,3 +918,3 @@ definition.additionalProperties = false;

let reffedDefinition: Definition;
if (asTypeAliasRef && reffedType!.getFlags() & (ts.TypeFlags.IndexedAccess | ts.TypeFlags.Index | ts.TypeFlags.Intersection) && symbol) {
if (asTypeAliasRef && reffedType && typ.symbol !== reffedType && symbol) {
reffedDefinition = this.getTypeDefinition(typ, true, undefined, symbol, symbol);

@@ -1189,2 +1189,3 @@ } else {

delete options.declaration;
delete options.declarationDir;
delete options.declarationMap;

@@ -1191,0 +1192,0 @@

Sorry, the diff of this file is not supported yet

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