Socket
Socket
Sign inDemoInstall

@orion-js/schema

Package Overview
Dependencies
Maintainers
3
Versions
110
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@orion-js/schema - npm Package Compare versions

Comparing version 3.6.1 to 3.6.5

lib/fieldTypes/any.d.ts

1

lib/fieldTypes/index.d.ts

@@ -12,3 +12,4 @@ declare const _default: {

blackbox: import("..").FieldType;
any: import("..").FieldType;
};
export default _default;

4

lib/fieldTypes/index.js

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

const blackbox_1 = __importDefault(require("./blackbox"));
const any_1 = __importDefault(require("./any"));
exports.default = {

@@ -27,3 +28,4 @@ array: array_1.default,

email: email_1.default,
blackbox: blackbox_1.default
blackbox: blackbox_1.default,
any: any_1.default
};

@@ -304,2 +304,11 @@ "use strict";

});
test('allow to set type any', async () => {
const schema = {
person: {
type: 'any'
}
};
const errors = await (0, index_1.default)(schema, { person: { lastName: 'López' } });
expect(errors).toEqual(null);
});
test('allow custom validation to pass an complex error object', async () => {

@@ -306,0 +315,0 @@ const schema = {

@@ -6,3 +6,3 @@ import { FieldType } from '../fieldType';

};
export type FieldTypesList = 'string' | 'date' | 'integer' | 'number' | 'ID' | 'boolean' | 'email' | 'blackbox';
export type FieldTypesList = 'string' | 'date' | 'integer' | 'number' | 'ID' | 'boolean' | 'email' | 'blackbox' | 'any';
export type TypedModelOnSchema = Function;

@@ -9,0 +9,0 @@ export type ConstructorsTypesList = Constructor<String> | Constructor<Number> | Constructor<Boolean> | Constructor<Date>;

{
"name": "@orion-js/schema",
"version": "3.6.1",
"version": "3.6.5",
"main": "lib/index.js",

@@ -34,3 +34,3 @@ "types": "lib/index.d.ts",

},
"gitHead": "ce643e657e199d1893c8c0f1d067d96e542f1796"
"gitHead": "1aa2e98c9e6cd7e82b19c335910d751ec2d2b03e"
}
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