MCPcopy Create free account
hub / github.com/json-editor/json-editor / errorsText

Method errorsText

docs/scripts/ajv-validator.js:3909–3917  ·  view source on GitHub ↗
(errors = this.errors, // optional array of validation errors
                           { separator = ", ", dataVar = "data" } = {} // optional options with properties `separator` and `dataVar`
                )

Source from the content-addressed store, hash-verified

3907 return this;
3908 }
3909 errorsText(errors = this.errors, // optional array of validation errors
3910 { separator = ", ", dataVar = "data" } = {} // optional options with properties `separator` and `dataVar`
3911 ) {
3912 if (!errors || errors.length === 0)
3913 return "No errors";
3914 return errors
3915 .map((e) => `${dataVar}${e.instancePath} ${e.message}`)
3916 .reduce((text, msg) => text + separator + msg);
3917 }
3918 $dataMetaSchema(metaSchema, keywordsJsonPointers) {
3919 const rules = this.RULES.all;
3920 metaSchema = JSON.parse(JSON.stringify(metaSchema));

Callers 2

validateSchemaMethod · 0.95
validateKeywordUsageFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected