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

@ovotech/laminar-cli

Package Overview
Dependencies
Maintainers
321
Versions
46
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ovotech/laminar-cli - npm Package Compare versions

Comparing version 0.13.18 to 0.13.19

2

dist/commands/laminar.js

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

.createCommand('laminar')
.version('0.13.18')
.version('0.13.19')
.description(`Laminar CLI - a tool for converting OpenApi and Avro Schemas to appropriate typescript types

@@ -18,0 +18,0 @@

@@ -31,2 +31,3 @@ "use strict";

};
const toTypeScriptName = (name) => name.replace(/-/g, '_');
const convertArrayType = (context, schema) => (0, traverse_1.isSchemaObject)(schema) && Array.isArray(schema.type)

@@ -66,3 +67,3 @@ ? (0, ts_compose_1.document)(context, ts_compose_1.Type.Union(schema.type.map(nodeType)))

if ((0, traverse_1.isReferenceObject)(schema)) {
const name = schema.$ref.split('/').reverse()[0];
const name = toTypeScriptName(schema.$ref.split('/').reverse()[0]);
if ((_a = context.identifiers) === null || _a === void 0 ? void 0 : _a[name]) {

@@ -69,0 +70,0 @@ return (0, ts_compose_1.document)(context, ts_compose_1.Type.Referance(name));

@@ -23,7 +23,7 @@ "use strict";

if (!context.refs[item.$ref]) {
throw new Error(`Reference Error [${JSON.stringify(item)}] not found`);
throw new Error(`Reference Error |${JSON.stringify(item)}| not found`);
}
const resolved = context.refs[item.$ref];
const resolved = (0, exports.getReferencedObject)(context.refs[item.$ref], guard, type, context);
if (!guard(resolved)) {
throw new Error(`Reference Error [${JSON.stringify(item)}] was not the expected type ${type}`);
throw new Error(`Reference Error, the reference |${JSON.stringify(item)}| which was resolved to |${JSON.stringify(resolved)}| was not the expected type "${type}"`);
}

@@ -30,0 +30,0 @@ return resolved;

{
"name": "@ovotech/laminar-cli",
"version": "0.13.18",
"version": "0.13.19",
"main": "dist/index.js",

@@ -5,0 +5,0 @@ "types": "dist/index.d.ts",

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