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

core-types-suretype

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

core-types-suretype - npm Package Compare versions

Comparing version 1.3.0 to 1.4.0

21

dist/lib/json-schema-to-suretype.js

@@ -90,5 +90,5 @@ "use strict";

{
title: 'These cyclic types need to be treated as raw ' +
'JSON Schema',
description: 'Cyclic types cannot be deduced from ' +
description: 'These cyclic types need to be treated as raw ' +
'JSON Schema\n\n' +
'Cyclic types cannot be deduced from ' +
'typeof in TypeScript',

@@ -186,4 +186,4 @@ })

return core_types_ts_1.helpers.wrapAnnotations(exportNode, {
title: `## Validate that a variable is a ${typeName}`,
description: '@returns ValidationResult',
description: `## Validate that a variable is a ${typeName}\n\n` +
'@returns ValidationResult',
});

@@ -207,4 +207,5 @@ }

return core_types_ts_1.helpers.wrapAnnotations(exportNode, {
title: `## Ensure a variable is a ${typeName}`,
description: [
`## Ensure a variable is a ${typeName}`,
'',
'This call will throw a ValidationError if the ' +

@@ -232,4 +233,4 @@ `variable isn't a ${typeName}.`,

return core_types_ts_1.helpers.wrapAnnotations(exportNode, {
title: `## Validates that a variable is a ${typeName}`,
description: '@returns boolean',
description: `## Validates that a variable is a ${typeName}\n\n` +
'@returns boolean',
});

@@ -250,3 +251,3 @@ }

? exportNode
: core_types_ts_1.helpers.wrapAnnotations(exportNode, { title: `The validation schema for a ${typeName}` });
: core_types_ts_1.helpers.wrapAnnotations(exportNode, { description: `The validation schema for a ${typeName}` });
}

@@ -261,3 +262,3 @@ function createValidatorSchema(ctx, exportSchema, typeName, validatorSchemaName, schemaObject) {

? exportNode
: core_types_ts_1.helpers.wrapAnnotations(exportNode, { title: `The validation schema for a ${typeName}` });
: core_types_ts_1.helpers.wrapAnnotations(exportNode, { description: `The validation schema for a ${typeName}` });
}

@@ -264,0 +265,0 @@ function createValidator(ctx, def, { topLevelName, required = false, includeAnnotations = true, } = {}) {

{
"name": "core-types-suretype",
"version": "1.3.0",
"version": "1.4.0",
"description": "core-types ⬌ SureType validator conversion",

@@ -42,5 +42,5 @@ "author": "Gustaf Räntilä",

"@types/json-schema": "^7.0.9",
"core-types": "^1.9.1",
"core-types-json-schema": "^1.6.0",
"core-types-ts": "^1.4.1",
"core-types": "^1.10.0",
"core-types-json-schema": "^1.6.1",
"core-types-ts": "^1.5.0",
"json-schema-cycles": "^1.1.0",

@@ -47,0 +47,0 @@ "jsonpos": "^1.1.0",

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