Socket
Socket
Sign inDemoInstall

@rjsf/validator-ajv8

Package Overview
Dependencies
Maintainers
2
Versions
75
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@rjsf/validator-ajv8 - npm Package Compare versions

Comparing version 5.12.0 to 5.12.1

4

dist/index.js

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

this.mainValidator = this.getValidator(rootSchema);
this.resolvedRootSchema = (0, import_utils4.retrieveSchema)(this, rootSchema, rootSchema);
}

@@ -307,3 +306,4 @@ /** Returns the precompiled validator associated with the given `schema` from the map of precompiled validator

rawValidation(schema, formData) {
if (!(0, import_isEqual.default)(schema, this.resolvedRootSchema)) {
const resolvedRootSchema = (0, import_utils4.retrieveSchema)(this, this.rootSchema, this.rootSchema, formData);
if (!(0, import_isEqual.default)(schema, resolvedRootSchema)) {
throw new Error(

@@ -310,0 +310,0 @@ "The schema associated with the precompiled schema differs from the schema provided for validation"

@@ -254,3 +254,2 @@ // src/validator.ts

this.mainValidator = this.getValidator(rootSchema);
this.resolvedRootSchema = retrieveSchema(this, rootSchema, rootSchema);
}

@@ -289,3 +288,4 @@ /** Returns the precompiled validator associated with the given `schema` from the map of precompiled validator

rawValidation(schema, formData) {
if (!isEqual(schema, this.resolvedRootSchema)) {
const resolvedRootSchema = retrieveSchema(this, this.rootSchema, this.rootSchema, formData);
if (!isEqual(schema, resolvedRootSchema)) {
throw new Error(

@@ -292,0 +292,0 @@ "The schema associated with the precompiled schema differs from the schema provided for validation"

@@ -224,3 +224,2 @@ (function (global, factory) {

this.mainValidator = this.getValidator(rootSchema);
this.resolvedRootSchema = utils.retrieveSchema(this, rootSchema, rootSchema);
}

@@ -259,3 +258,4 @@ /** Returns the precompiled validator associated with the given `schema` from the map of precompiled validator

rawValidation(schema, formData) {
if (!isEqual(schema, this.resolvedRootSchema)) {
const resolvedRootSchema = utils.retrieveSchema(this, this.rootSchema, this.rootSchema, formData);
if (!isEqual(schema, resolvedRootSchema)) {
throw new Error(

@@ -262,0 +262,0 @@ "The schema associated with the precompiled schema differs from the schema provided for validation"

@@ -13,7 +13,2 @@ import { CustomValidator, ErrorSchema, ErrorTransformer, FormContextType, RJSFSchema, StrictRJSFSchema, UiSchema, ValidationData, ValidatorType } from '@rjsf/utils';

readonly rootSchema: S;
/** The root schema resolved top level refs
*
* @private
*/
readonly resolvedRootSchema: S;
/** The `ValidatorFunctions` map used to construct this validator

@@ -20,0 +15,0 @@ *

@@ -21,3 +21,2 @@ import get from 'lodash/get';

this.mainValidator = this.getValidator(rootSchema);
this.resolvedRootSchema = retrieveSchema(this, rootSchema, rootSchema);
}

@@ -56,3 +55,4 @@ /** Returns the precompiled validator associated with the given `schema` from the map of precompiled validator

rawValidation(schema, formData) {
if (!isEqual(schema, this.resolvedRootSchema)) {
const resolvedRootSchema = retrieveSchema(this, this.rootSchema, this.rootSchema, formData);
if (!isEqual(schema, resolvedRootSchema)) {
throw new Error('The schema associated with the precompiled schema differs from the schema provided for validation');

@@ -59,0 +59,0 @@ }

{
"name": "@rjsf/validator-ajv8",
"version": "5.12.0",
"version": "5.12.1",
"main": "dist/index.js",

@@ -52,3 +52,3 @@ "module": "lib/index.js",

"@babel/preset-typescript": "^7.22.5",
"@rjsf/utils": "^5.12.0",
"@rjsf/utils": "^5.12.1",
"@types/json-schema": "^7.0.12",

@@ -86,3 +86,3 @@ "@types/lodash": "^4.14.196",

"license": "Apache-2.0",
"gitHead": "bab797c43a34e5ec68a84b2bdabb3c377e46b092"
"gitHead": "de6477730fd16a07def501c2cb761af9c3f4c247"
}

@@ -39,8 +39,2 @@ import { ErrorObject } from 'ajv';

/** The root schema resolved top level refs
*
* @private
*/
readonly resolvedRootSchema: S;
/** The `ValidatorFunctions` map used to construct this validator

@@ -76,3 +70,2 @@ *

this.mainValidator = this.getValidator(rootSchema);
this.resolvedRootSchema = retrieveSchema(this, rootSchema, rootSchema);
}

@@ -114,3 +107,4 @@

rawValidation<Result = any>(schema: S, formData?: T): RawValidationErrorsType<Result> {
if (!isEqual(schema, this.resolvedRootSchema)) {
const resolvedRootSchema = retrieveSchema(this, this.rootSchema, this.rootSchema, formData);
if (!isEqual(schema, resolvedRootSchema)) {
throw new Error(

@@ -117,0 +111,0 @@ 'The schema associated with the precompiled schema differs from the schema provided for validation'

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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