openapi-gen-typescript
Advanced tools
Comparing version 0.2.4 to 0.2.5
@@ -72,2 +72,6 @@ "use strict"; | ||
} | ||
else if (/^\(([\s\S]+)\)$/.test(jsonSchema)) { | ||
jsonSchema = jsonSchema.replace(/^\(([\s\S]+)\)$/, '$1'); | ||
responseTypeNames.push(responseTypeName); | ||
} | ||
else { | ||
@@ -285,3 +289,4 @@ responseTypeNames.push(responseTypeName); | ||
.replace(/ interface | type = /g, ' class ') | ||
.replace(/ type ([^=]+) = components.([a-zA-Z.]+)[;{}]?/g, ' class $1 extends $2 {}'); | ||
.replace(/ type ([^=]+) = components.([a-zA-Z.]+)[;{}]?/g, ' class $1 extends $2 {}') | ||
.replace(/ type ([^=]+) = /g, ' class $1 '); | ||
}); | ||
@@ -288,0 +293,0 @@ pathsMap[namespaceName] = { |
{ | ||
"name": "openapi-gen-typescript", | ||
"version": "0.2.4", | ||
"version": "0.2.5", | ||
"main": "dist/index.js", | ||
@@ -5,0 +5,0 @@ "types": "dist/index.d.ts", |
@@ -105,2 +105,5 @@ // @ts-ignore | ||
responseTypeNames.push(`${responseTypeName}[]`); | ||
} else if (/^\(([\s\S]+)\)$/.test(jsonSchema)) { | ||
jsonSchema = jsonSchema.replace(/^\(([\s\S]+)\)$/, '$1'); | ||
responseTypeNames.push(responseTypeName); | ||
} else { | ||
@@ -416,3 +419,4 @@ responseTypeNames.push(responseTypeName); | ||
.replace(/ interface | type = /g, ' class ') | ||
.replace(/ type ([^=]+) = components.([a-zA-Z.]+)[;{}]?/g, ' class $1 extends $2 {}'); | ||
.replace(/ type ([^=]+) = components.([a-zA-Z.]+)[;{}]?/g, ' class $1 extends $2 {}') | ||
.replace(/ type ([^=]+) = /g, ' class $1 '); | ||
}); | ||
@@ -419,0 +423,0 @@ pathsMap[namespaceName] = { |
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
67564
1445