summaryrefslogtreecommitdiffstats
path: root/node_modules/schema-utils/declarations/validate.d.ts
diff options
context:
space:
mode:
authorGravatar Piotr Russ <mail@pruss.it> 2020-11-16 00:10:28 +0100
committerGravatar Piotr Russ <mail@pruss.it> 2020-11-16 00:10:28 +0100
commite06ec920f7a5d784e674c4c4b4e6d1da3dc7391d (patch)
tree55713f725f77b44ebfec86e4eec3ce33e71458ca /node_modules/schema-utils/declarations/validate.d.ts
downloadwebsite_creator-e06ec920f7a5d784e674c4c4b4e6d1da3dc7391d.tar.gz
website_creator-e06ec920f7a5d784e674c4c4b4e6d1da3dc7391d.tar.bz2
website_creator-e06ec920f7a5d784e674c4c4b4e6d1da3dc7391d.zip
api, login, auth
Diffstat (limited to 'node_modules/schema-utils/declarations/validate.d.ts')
-rw-r--r--node_modules/schema-utils/declarations/validate.d.ts39
1 files changed, 39 insertions, 0 deletions
diff --git a/node_modules/schema-utils/declarations/validate.d.ts b/node_modules/schema-utils/declarations/validate.d.ts
new file mode 100644
index 0000000..035c52c
--- /dev/null
+++ b/node_modules/schema-utils/declarations/validate.d.ts
@@ -0,0 +1,39 @@
+export type JSONSchema4 = import('json-schema').JSONSchema4;
+export type JSONSchema6 = import('json-schema').JSONSchema6;
+export type JSONSchema7 = import('json-schema').JSONSchema7;
+export type ErrorObject = import('ajv').ErrorObject;
+export type Extend = {
+ formatMinimum?: number | undefined;
+ formatMaximum?: number | undefined;
+ formatExclusiveMinimum?: boolean | undefined;
+ formatExclusiveMaximum?: boolean | undefined;
+};
+export type Schema =
+ | (import('json-schema').JSONSchema4 & Extend)
+ | (import('json-schema').JSONSchema6 & Extend)
+ | (import('json-schema').JSONSchema7 & Extend);
+export type SchemaUtilErrorObject = import('ajv').ErrorObject & {
+ children?: import('ajv').ErrorObject[] | undefined;
+};
+export type PostFormatter = (
+ formattedError: string,
+ error: SchemaUtilErrorObject
+) => string;
+export type ValidationErrorConfiguration = {
+ name?: string | undefined;
+ baseDataPath?: string | undefined;
+ postFormatter?: PostFormatter | undefined;
+};
+/**
+ * @param {Schema} schema
+ * @param {Array<object> | object} options
+ * @param {ValidationErrorConfiguration=} configuration
+ * @returns {void}
+ */
+export function validate(
+ schema: Schema,
+ options: Array<object> | object,
+ configuration?: ValidationErrorConfiguration | undefined
+): void;
+import ValidationError from './ValidationError';
+export { ValidationError };