@hyperjump/json-schema 1.6.6 → 1.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +247 -255
- package/annotations/annotated-instance.js +3 -3
- package/annotations/index.d.ts +7 -1
- package/annotations/index.js +3 -3
- package/bundle/index.d.ts +1 -5
- package/bundle/index.js +125 -121
- package/draft-04/additionalItems.js +6 -7
- package/draft-04/dependencies.js +5 -5
- package/draft-04/index.js +2 -2
- package/draft-04/items.js +5 -5
- package/draft-04/maximum.js +8 -8
- package/draft-04/minimum.js +8 -8
- package/draft-06/contains.js +2 -2
- package/draft-06/index.js +3 -2
- package/draft-07/index.js +3 -2
- package/draft-2019-09/index.js +9 -11
- package/draft-2020-12/dynamicRef.js +5 -5
- package/draft-2020-12/index.js +11 -13
- package/lib/common.d.ts +1 -1
- package/lib/common.js +44 -60
- package/lib/configuration.js +0 -6
- package/lib/core.js +32 -30
- package/lib/experimental.d.ts +75 -5
- package/lib/experimental.js +2 -2
- package/lib/index.d.ts +43 -11
- package/lib/index.js +11 -11
- package/lib/instance.d.ts +1 -17
- package/lib/instance.js +3 -3
- package/lib/keywords/additionalProperties.js +12 -13
- package/lib/keywords/allOf.js +3 -3
- package/lib/keywords/anyOf.js +3 -3
- package/lib/keywords/conditional.js +6 -7
- package/lib/keywords/const.js +2 -2
- package/lib/keywords/contains.js +14 -35
- package/lib/keywords/contentSchema.js +1 -1
- package/lib/keywords/definitions.js +2 -2
- package/lib/keywords/dependentRequired.js +4 -4
- package/lib/keywords/dependentSchemas.js +5 -5
- package/lib/keywords/dynamicRef.js +10 -5
- package/lib/keywords/else.js +5 -6
- package/lib/keywords/enum.js +4 -4
- package/lib/keywords/exclusiveMaximum.js +3 -3
- package/lib/keywords/exclusiveMinimum.js +3 -3
- package/lib/keywords/if.js +1 -1
- package/lib/keywords/itemPattern.js +17 -14
- package/lib/keywords/items.js +6 -7
- package/lib/keywords/maxItems.js +3 -3
- package/lib/keywords/maxLength.js +3 -3
- package/lib/keywords/maxProperties.js +3 -3
- package/lib/keywords/maximum.js +3 -3
- package/lib/keywords/meta-data.js +1 -1
- package/lib/keywords/minItems.js +3 -3
- package/lib/keywords/minLength.js +3 -3
- package/lib/keywords/minProperties.js +3 -3
- package/lib/keywords/minimum.js +3 -3
- package/lib/keywords/multipleOf.js +3 -3
- package/lib/keywords/not.js +1 -1
- package/lib/keywords/oneOf.js +3 -3
- package/lib/keywords/pattern.js +3 -3
- package/lib/keywords/patternProperties.js +5 -5
- package/lib/keywords/prefixItems.js +5 -5
- package/lib/keywords/properties.js +5 -5
- package/lib/keywords/propertyDependencies.js +6 -7
- package/lib/keywords/propertyNames.js +2 -2
- package/lib/keywords/ref.js +2 -7
- package/lib/keywords/requireAllExcept.js +8 -9
- package/lib/keywords/required.js +3 -3
- package/lib/keywords/then.js +5 -5
- package/lib/keywords/type.js +9 -3
- package/lib/keywords/unevaluatedItems.js +4 -4
- package/lib/keywords/unevaluatedProperties.js +4 -5
- package/lib/keywords/uniqueItems.js +3 -3
- package/lib/keywords/validation.js +11 -23
- package/lib/keywords.js +30 -4
- package/lib/openapi.js +19 -6
- package/lib/schema.js +235 -233
- package/openapi-3-0/index.js +5 -5
- package/openapi-3-0/type.js +13 -7
- package/openapi-3-1/index.d.ts +1 -1
- package/openapi-3-1/index.js +22 -21
- package/openapi-3-1/{schema-base/2022-10-07.js → schema-base.js} +12 -2
- package/openapi-3-1/schema-draft-04.js +33 -0
- package/openapi-3-1/schema-draft-06.js +33 -0
- package/openapi-3-1/schema-draft-07.js +33 -0
- package/openapi-3-1/schema-draft-2019-09.js +33 -0
- package/openapi-3-1/schema-draft-2020-12.js +33 -0
- package/package.json +14 -16
- package/stable/index.js +10 -10
- package/annotations/tests/applicators.json +0 -375
- package/annotations/tests/content.json +0 -57
- package/annotations/tests/core.json +0 -33
- package/annotations/tests/format.json +0 -20
- package/annotations/tests/meta-data.json +0 -128
- package/annotations/tests/unevaluated.json +0 -557
- package/annotations/tests/unknown.json +0 -87
- package/annotations/tests/validation.json +0 -328
- package/annotations/validation-error.d.ts +0 -8
- package/bundle/file.json +0 -57
- package/draft-2019-09/contains.js +0 -44
- package/lib/configuration.d.ts +0 -9
- package/lib/context-uri.browser.js +0 -1
- package/lib/context-uri.js +0 -4
- package/lib/core.d.ts +0 -48
- package/lib/fetch.browser.js +0 -1
- package/lib/fetch.js +0 -20
- package/lib/invalid-schema-error.d.ts +0 -8
- package/lib/keywords.d.ts +0 -19
- package/lib/media-types.d.ts +0 -11
- package/lib/media-types.js +0 -48
- package/lib/reference.d.ts +0 -11
- package/lib/reference.js +0 -11
- package/lib/schema.d.ts +0 -60
- /package/openapi-3-0/{schema/2021-09-28.js → schema.js} +0 -0
- /package/openapi-3-1/{schema/2022-10-07.js → schema.js} +0 -0
package/openapi-3-1/index.js
CHANGED
|
@@ -1,11 +1,16 @@
|
|
|
1
|
-
import { addKeyword, defineVocabulary
|
|
2
|
-
import {
|
|
1
|
+
import { addKeyword, defineVocabulary } from "../lib/keywords.js";
|
|
2
|
+
import { registerSchema } from "../lib/index.js";
|
|
3
3
|
import "../lib/openapi.js";
|
|
4
4
|
|
|
5
5
|
import dialectSchema from "./dialect/base.js";
|
|
6
6
|
import vocabularySchema from "./meta/base.js";
|
|
7
|
-
import
|
|
8
|
-
import
|
|
7
|
+
import schema from "./schema.js";
|
|
8
|
+
import schemaBase from "./schema-base.js";
|
|
9
|
+
import schemaDraft2020 from "./schema-draft-2020-12.js";
|
|
10
|
+
import schemaDraft2019 from "./schema-draft-2019-09.js";
|
|
11
|
+
import schemaDraft07 from "./schema-draft-07.js";
|
|
12
|
+
import schemaDraft06 from "./schema-draft-06.js";
|
|
13
|
+
import schemaDraft04 from "./schema-draft-04.js";
|
|
9
14
|
|
|
10
15
|
import discriminator from "../openapi-3-0/discriminator.js";
|
|
11
16
|
import example from "../openapi-3-0/example.js";
|
|
@@ -25,24 +30,20 @@ defineVocabulary("https://spec.openapis.org/oas/3.1/vocab/base", {
|
|
|
25
30
|
"xml": "https://spec.openapis.org/oas/3.0/keyword/xml"
|
|
26
31
|
});
|
|
27
32
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
"https://json-schema.org/draft/2020-12/vocab/applicator": true,
|
|
31
|
-
"https://json-schema.org/draft/2020-12/vocab/validation": true,
|
|
32
|
-
"https://json-schema.org/draft/2020-12/vocab/meta-data": true,
|
|
33
|
-
"https://json-schema.org/draft/2020-12/vocab/format-annotation": true,
|
|
34
|
-
"https://json-schema.org/draft/2020-12/vocab/content": true,
|
|
35
|
-
"https://json-schema.org/draft/2020-12/vocab/unevaluated": true,
|
|
36
|
-
"https://spec.openapis.org/oas/3.1/vocab/base": false
|
|
37
|
-
}, true);
|
|
38
|
-
|
|
39
|
-
addSchema(vocabularySchema);
|
|
40
|
-
addSchema(dialectSchema);
|
|
33
|
+
registerSchema(vocabularySchema);
|
|
34
|
+
registerSchema(dialectSchema);
|
|
41
35
|
|
|
42
36
|
// Current Schemas
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
37
|
+
registerSchema(schema, "https://spec.openapis.org/oas/3.1/schema");
|
|
38
|
+
registerSchema(schema, "https://spec.openapis.org/oas/3.1/schema/latest");
|
|
39
|
+
registerSchema(schemaBase, "https://spec.openapis.org/oas/3.1/schema-base");
|
|
40
|
+
registerSchema(schemaBase, "https://spec.openapis.org/oas/3.1/schema-base/latest");
|
|
41
|
+
|
|
42
|
+
// Alternative dialect schemas
|
|
43
|
+
registerSchema(schemaDraft2020, "https://spec.openapis.org/oas/3.1/schema-draft-2020-12");
|
|
44
|
+
registerSchema(schemaDraft2019, "https://spec.openapis.org/oas/3.1/schema-draft-2019-09");
|
|
45
|
+
registerSchema(schemaDraft07, "https://spec.openapis.org/oas/3.1/schema-draft-07");
|
|
46
|
+
registerSchema(schemaDraft06, "https://spec.openapis.org/oas/3.1/schema-draft-06");
|
|
47
|
+
registerSchema(schemaDraft04, "https://spec.openapis.org/oas/3.1/schema-draft-04");
|
|
47
48
|
|
|
48
49
|
export * from "../draft-2020-12/index.js";
|
|
@@ -1,10 +1,20 @@
|
|
|
1
1
|
export default {
|
|
2
|
-
"$id": "https://spec.openapis.org/oas/3.1/schema-base/2022-10-07",
|
|
3
2
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4
3
|
|
|
4
|
+
"$vocabulary": {
|
|
5
|
+
"https://json-schema.org/draft/2020-12/vocab/core": true,
|
|
6
|
+
"https://json-schema.org/draft/2020-12/vocab/applicator": true,
|
|
7
|
+
"https://json-schema.org/draft/2020-12/vocab/unevaluated": true,
|
|
8
|
+
"https://json-schema.org/draft/2020-12/vocab/validation": true,
|
|
9
|
+
"https://json-schema.org/draft/2020-12/vocab/meta-data": true,
|
|
10
|
+
"https://json-schema.org/draft/2020-12/vocab/format-annotation": true,
|
|
11
|
+
"https://json-schema.org/draft/2020-12/vocab/content": true,
|
|
12
|
+
"https://spec.openapis.org/oas/3.1/vocab/base": false
|
|
13
|
+
},
|
|
14
|
+
|
|
5
15
|
"description": "The description of OpenAPI v3.1.x documents using the OpenAPI JSON Schema dialect, as defined by https://spec.openapis.org/oas/v3.1.0",
|
|
6
16
|
|
|
7
|
-
"$ref": "https://spec.openapis.org/oas/3.1/schema
|
|
17
|
+
"$ref": "https://spec.openapis.org/oas/3.1/schema",
|
|
8
18
|
"properties": {
|
|
9
19
|
"jsonSchemaDialect": { "$ref": "#/$defs/dialect" }
|
|
10
20
|
},
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
|
|
4
|
+
"$vocabulary": {
|
|
5
|
+
"https://json-schema.org/draft/2020-12/vocab/core": true,
|
|
6
|
+
"https://json-schema.org/draft/2020-12/vocab/applicator": true,
|
|
7
|
+
"https://json-schema.org/draft/2020-12/vocab/unevaluated": true,
|
|
8
|
+
"https://json-schema.org/draft/2020-12/vocab/validation": true,
|
|
9
|
+
"https://json-schema.org/draft/2020-12/vocab/meta-data": true,
|
|
10
|
+
"https://json-schema.org/draft/2020-12/vocab/format-annotation": true,
|
|
11
|
+
"https://json-schema.org/draft/2020-12/vocab/content": true,
|
|
12
|
+
"https://spec.openapis.org/oas/3.1/vocab/base": false
|
|
13
|
+
},
|
|
14
|
+
|
|
15
|
+
"description": "OpenAPI v3.1.x documents using draft-04 JSON Schemas",
|
|
16
|
+
|
|
17
|
+
"$ref": "https://spec.openapis.org/oas/3.1/schema",
|
|
18
|
+
"properties": {
|
|
19
|
+
"jsonSchemaDialect": { "$ref": "#/$defs/dialect" }
|
|
20
|
+
},
|
|
21
|
+
|
|
22
|
+
"$defs": {
|
|
23
|
+
"dialect": { "const": "http://json-schema.org/draft-04/schema#" },
|
|
24
|
+
|
|
25
|
+
"schema": {
|
|
26
|
+
"$dynamicAnchor": "meta",
|
|
27
|
+
"$ref": "https://spec.openapis.org/oas/3.1/dialect/base",
|
|
28
|
+
"properties": {
|
|
29
|
+
"$schema": { "$ref": "#/$defs/dialect" }
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
|
|
4
|
+
"$vocabulary": {
|
|
5
|
+
"https://json-schema.org/draft/2020-12/vocab/core": true,
|
|
6
|
+
"https://json-schema.org/draft/2020-12/vocab/applicator": true,
|
|
7
|
+
"https://json-schema.org/draft/2020-12/vocab/unevaluated": true,
|
|
8
|
+
"https://json-schema.org/draft/2020-12/vocab/validation": true,
|
|
9
|
+
"https://json-schema.org/draft/2020-12/vocab/meta-data": true,
|
|
10
|
+
"https://json-schema.org/draft/2020-12/vocab/format-annotation": true,
|
|
11
|
+
"https://json-schema.org/draft/2020-12/vocab/content": true,
|
|
12
|
+
"https://spec.openapis.org/oas/3.1/vocab/base": false
|
|
13
|
+
},
|
|
14
|
+
|
|
15
|
+
"description": "OpenAPI v3.1.x documents using draft-06 JSON Schemas",
|
|
16
|
+
|
|
17
|
+
"$ref": "https://spec.openapis.org/oas/3.1/schema",
|
|
18
|
+
"properties": {
|
|
19
|
+
"jsonSchemaDialect": { "$ref": "#/$defs/dialect" }
|
|
20
|
+
},
|
|
21
|
+
|
|
22
|
+
"$defs": {
|
|
23
|
+
"dialect": { "const": "http://json-schema.org/draft-06/schema#" },
|
|
24
|
+
|
|
25
|
+
"schema": {
|
|
26
|
+
"$dynamicAnchor": "meta",
|
|
27
|
+
"$ref": "https://spec.openapis.org/oas/3.1/dialect/base",
|
|
28
|
+
"properties": {
|
|
29
|
+
"$schema": { "$ref": "#/$defs/dialect" }
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
|
|
4
|
+
"$vocabulary": {
|
|
5
|
+
"https://json-schema.org/draft/2020-12/vocab/core": true,
|
|
6
|
+
"https://json-schema.org/draft/2020-12/vocab/applicator": true,
|
|
7
|
+
"https://json-schema.org/draft/2020-12/vocab/unevaluated": true,
|
|
8
|
+
"https://json-schema.org/draft/2020-12/vocab/validation": true,
|
|
9
|
+
"https://json-schema.org/draft/2020-12/vocab/meta-data": true,
|
|
10
|
+
"https://json-schema.org/draft/2020-12/vocab/format-annotation": true,
|
|
11
|
+
"https://json-schema.org/draft/2020-12/vocab/content": true,
|
|
12
|
+
"https://spec.openapis.org/oas/3.1/vocab/base": false
|
|
13
|
+
},
|
|
14
|
+
|
|
15
|
+
"description": "OpenAPI v3.1.x documents using draft-07 JSON Schemas",
|
|
16
|
+
|
|
17
|
+
"$ref": "https://spec.openapis.org/oas/3.1/schema",
|
|
18
|
+
"properties": {
|
|
19
|
+
"jsonSchemaDialect": { "$ref": "#/$defs/dialect" }
|
|
20
|
+
},
|
|
21
|
+
|
|
22
|
+
"$defs": {
|
|
23
|
+
"dialect": { "const": "http://json-schema.org/draft-07/schema#" },
|
|
24
|
+
|
|
25
|
+
"schema": {
|
|
26
|
+
"$dynamicAnchor": "meta",
|
|
27
|
+
"$ref": "https://spec.openapis.org/oas/3.1/dialect/base",
|
|
28
|
+
"properties": {
|
|
29
|
+
"$schema": { "$ref": "#/$defs/dialect" }
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
|
|
4
|
+
"$vocabulary": {
|
|
5
|
+
"https://json-schema.org/draft/2020-12/vocab/core": true,
|
|
6
|
+
"https://json-schema.org/draft/2020-12/vocab/applicator": true,
|
|
7
|
+
"https://json-schema.org/draft/2020-12/vocab/unevaluated": true,
|
|
8
|
+
"https://json-schema.org/draft/2020-12/vocab/validation": true,
|
|
9
|
+
"https://json-schema.org/draft/2020-12/vocab/meta-data": true,
|
|
10
|
+
"https://json-schema.org/draft/2020-12/vocab/format-annotation": true,
|
|
11
|
+
"https://json-schema.org/draft/2020-12/vocab/content": true,
|
|
12
|
+
"https://spec.openapis.org/oas/3.1/vocab/base": false
|
|
13
|
+
},
|
|
14
|
+
|
|
15
|
+
"description": "openapi v3.1.x documents using 2019-09 json schemas",
|
|
16
|
+
|
|
17
|
+
"$ref": "https://spec.openapis.org/oas/3.1/schema",
|
|
18
|
+
"properties": {
|
|
19
|
+
"jsonschemadialect": { "$ref": "#/$defs/dialect" }
|
|
20
|
+
},
|
|
21
|
+
|
|
22
|
+
"$defs": {
|
|
23
|
+
"dialect": { "const": "https://json-schema.org/draft/2019-09/schema" },
|
|
24
|
+
|
|
25
|
+
"schema": {
|
|
26
|
+
"$dynamicanchor": "meta",
|
|
27
|
+
"$ref": "https://spec.openapis.org/oas/3.1/dialect/base",
|
|
28
|
+
"properties": {
|
|
29
|
+
"$schema": { "$ref": "#/$defs/dialect" }
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
|
|
4
|
+
"$vocabulary": {
|
|
5
|
+
"https://json-schema.org/draft/2020-12/vocab/core": true,
|
|
6
|
+
"https://json-schema.org/draft/2020-12/vocab/applicator": true,
|
|
7
|
+
"https://json-schema.org/draft/2020-12/vocab/unevaluated": true,
|
|
8
|
+
"https://json-schema.org/draft/2020-12/vocab/validation": true,
|
|
9
|
+
"https://json-schema.org/draft/2020-12/vocab/meta-data": true,
|
|
10
|
+
"https://json-schema.org/draft/2020-12/vocab/format-annotation": true,
|
|
11
|
+
"https://json-schema.org/draft/2020-12/vocab/content": true,
|
|
12
|
+
"https://spec.openapis.org/oas/3.1/vocab/base": false
|
|
13
|
+
},
|
|
14
|
+
|
|
15
|
+
"description": "openapi v3.1.x documents using 2020-12 json schemas",
|
|
16
|
+
|
|
17
|
+
"$ref": "https://spec.openapis.org/oas/3.1/schema",
|
|
18
|
+
"properties": {
|
|
19
|
+
"jsonschemadialect": { "$ref": "#/$defs/dialect" }
|
|
20
|
+
},
|
|
21
|
+
|
|
22
|
+
"$defs": {
|
|
23
|
+
"dialect": { "const": "https://json-schema.org/draft/2020-12/schema" },
|
|
24
|
+
|
|
25
|
+
"schema": {
|
|
26
|
+
"$dynamicanchor": "meta",
|
|
27
|
+
"$ref": "https://spec.openapis.org/oas/3.1/dialect/base",
|
|
28
|
+
"properties": {
|
|
29
|
+
"$schema": { "$ref": "#/$defs/dialect" }
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hyperjump/json-schema",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.7.0",
|
|
4
4
|
"description": "A JSON Schema validator with support for custom keywords, vocabularies, and dialects",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./stable/index.js",
|
|
@@ -14,22 +14,20 @@
|
|
|
14
14
|
"./openapi-3-0": "./openapi-3-0/index.js",
|
|
15
15
|
"./openapi-3-1": "./openapi-3-1/index.js",
|
|
16
16
|
"./experimental": "./lib/experimental.js",
|
|
17
|
-
"./schema/experimental": "./lib/schema.js",
|
|
18
17
|
"./instance/experimental": "./lib/instance.js",
|
|
19
18
|
"./annotations/experimental": "./annotations/index.js",
|
|
20
19
|
"./annotated-instance/experimental": "./annotations/annotated-instance.js",
|
|
21
20
|
"./bundle": "./bundle/index.js"
|
|
22
21
|
},
|
|
23
|
-
"browser": {
|
|
24
|
-
"./lib/fetch.js": "./lib/fetch.browser.js",
|
|
25
|
-
"./lib/context-uri.js": "./lib/context-uri.browser.js"
|
|
26
|
-
},
|
|
27
22
|
"scripts": {
|
|
28
23
|
"clean": "xargs -a .gitignore rm -rf",
|
|
29
24
|
"lint": "eslint lib stable draft-* openapi-* bundle annotations",
|
|
30
|
-
"test": "
|
|
25
|
+
"test": "vitest --watch=false"
|
|
26
|
+
},
|
|
27
|
+
"repository": {
|
|
28
|
+
"type": "git",
|
|
29
|
+
"url": "git+https://github.com/hyperjump-io/json-schema.git"
|
|
31
30
|
},
|
|
32
|
-
"repository": "github:hyperjump-io/json-schema",
|
|
33
31
|
"keywords": [
|
|
34
32
|
"JSON Schema",
|
|
35
33
|
"json-schema",
|
|
@@ -51,20 +49,21 @@
|
|
|
51
49
|
"url": "https://github.com/sponsors/jdesrosiers"
|
|
52
50
|
},
|
|
53
51
|
"devDependencies": {
|
|
54
|
-
"@types/
|
|
55
|
-
"@types/mocha": "*",
|
|
52
|
+
"@types/content-type": "*",
|
|
56
53
|
"@types/node": "*",
|
|
54
|
+
"@types/uuid": "*",
|
|
57
55
|
"@typescript-eslint/eslint-plugin": "*",
|
|
58
56
|
"@typescript-eslint/parser": "*",
|
|
59
|
-
"
|
|
57
|
+
"@vitest/coverage-v8": "*",
|
|
60
58
|
"eslint": "*",
|
|
59
|
+
"eslint-import-resolver-exports": "*",
|
|
61
60
|
"eslint-import-resolver-node": "*",
|
|
62
61
|
"eslint-import-resolver-typescript": "*",
|
|
63
62
|
"eslint-plugin-import": "*",
|
|
64
63
|
"json-schema-test-suite": "github:json-schema-org/JSON-Schema-Test-Suite",
|
|
65
|
-
"mocha": "*",
|
|
66
|
-
"ts-node": "*",
|
|
67
64
|
"typescript": "*",
|
|
65
|
+
"undici": "*",
|
|
66
|
+
"vitest": "*",
|
|
68
67
|
"yaml": "*"
|
|
69
68
|
},
|
|
70
69
|
"dependencies": {
|
|
@@ -74,10 +73,9 @@
|
|
|
74
73
|
"content-type": "^1.0.4",
|
|
75
74
|
"fastest-stable-stringify": "^2.0.2",
|
|
76
75
|
"just-curry-it": "^5.3.0",
|
|
77
|
-
"undici": "^5.19.1",
|
|
78
76
|
"uuid": "^9.0.0"
|
|
79
77
|
},
|
|
80
|
-
"
|
|
81
|
-
"
|
|
78
|
+
"peerDependencies": {
|
|
79
|
+
"@hyperjump/browser": "^1.1.0"
|
|
82
80
|
}
|
|
83
81
|
}
|
package/stable/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineVocabulary, loadDialect } from "../lib/keywords.js";
|
|
2
|
-
import {
|
|
2
|
+
import { registerSchema } from "../lib/index.js";
|
|
3
3
|
|
|
4
4
|
import metaSchema from "./validation.js";
|
|
5
5
|
import coreMetaSchema from "./meta/core.js";
|
|
@@ -108,14 +108,14 @@ loadDialect(dialectId, {
|
|
|
108
108
|
"https://json-schema.org/vocab/unevaluated": true
|
|
109
109
|
});
|
|
110
110
|
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
111
|
+
registerSchema(metaSchema, dialectId);
|
|
112
|
+
registerSchema(coreMetaSchema, "https://json-schema.org/meta/core");
|
|
113
|
+
registerSchema(applicatorMetaSchema, "https://json-schema.org/meta/applicator");
|
|
114
|
+
registerSchema(validationMetaSchema, "https://json-schema.org/meta/validation");
|
|
115
|
+
registerSchema(metaDataMetaSchema, "https://json-schema.org/meta/meta-data");
|
|
116
|
+
registerSchema(formatAnnotationMetaSchema, "https://json-schema.org/meta/format-annotation");
|
|
117
|
+
registerSchema(formatAssertionMetaSchema, "https://json-schema.org/meta/format-assertion");
|
|
118
|
+
registerSchema(contentMetaSchema, "https://json-schema.org/meta/content");
|
|
119
|
+
registerSchema(unevaluatedMetaSchema, "https://json-schema.org/meta/unevaluated");
|
|
120
120
|
|
|
121
121
|
export * from "../lib/index.js";
|