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

@travetto/schema

Package Overview
Dependencies
Maintainers
1
Versions
323
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@travetto/schema - npm Package Compare versions

Comparing version 0.0.26 to 0.0.27

2

package.json

@@ -28,3 +28,3 @@ {

},
"version": "0.0.26"
"version": "0.0.27"
}

@@ -40,3 +40,3 @@ import { CommonRegExp, SchemaRegistry, ClassList, ValidatorFn } from '../service';

export const Url = (message?: string) => Match(CommonRegExp.url, message);
export const Precision = (precision: number) => prop({ precision });
export const Precision = (precision: number) => prop({ declared: { precision } });
export const Integer = () => prop({ precision: 0 });

@@ -43,0 +43,0 @@ export const Float = () => prop({ precision: 10 });

@@ -100,6 +100,2 @@ import { MetadataRegistry, RootRegistry, Class, ChangeEvent } from '@travetto/registry';

registerPendingFieldConfigSpecifierType(target: Class, prop: string, specifier: string) {
return this.registerPendingFieldFacet(target, prop, { declared: { specifier } });
}
registerPendingFieldConfig(target: Class, prop: string, type: ClassList, specifier?: string) {

@@ -106,0 +102,0 @@ const isArray = Array.isArray(type);

@@ -28,6 +28,10 @@ import { Class } from '@travetto/registry';

aliases?: string[];
declared: { type: Class<any>, array: boolean, specifier?: string };
declared: {
type: Class<any>;
array: boolean;
specifier?: string;
precision?: number
};
required?: { message?: string };
match?: { re: RegExp, message?: string };
precision?: number;
min?: { n: number | Date, message?: string };

@@ -34,0 +38,0 @@ max?: { n: number | Date, message?: string };

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