Skip to content

Commit

Permalink
docstring
Browse files Browse the repository at this point in the history
  • Loading branch information
robertf224 committed Sep 10, 2024
1 parent 74abd04 commit 40eb0bd
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions libraries/node-core-library/src/JsonSchema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,9 @@ export interface IJsonSchemaLoadOptions {
schemaVersion?: JsonSchemaVersion;

/**
* Any custom formats to consider during validation.
* Any custom formats to consider during validation. Some standard formats are supported
* out-of-the-box (e.g. emails, uris), but additional formats can be defined here. You could
* for example define generic numeric formats (e.g. uint8) or domain-specific formats.
*/
customFormats?: Record<string, IJsonSchemaCustomFormat<string> | IJsonSchemaCustomFormat<number>>;
}
Expand Down Expand Up @@ -339,7 +341,7 @@ export class JsonSchema {
if (this._customFormats) {
for (const [name, format] of Object.entries(this._customFormats)) {
validator.addFormat(name, { ...format, async: false });
});
}
}

const collectedSchemas: JsonSchema[] = [];
Expand Down

0 comments on commit 40eb0bd

Please sign in to comment.