Skip to content

Commit 76505b9

Browse files
committed
add comment ref back; update appendix format per PR discussion
1 parent d41808d commit 76505b9

File tree

1 file changed

+26
-16
lines changed

1 file changed

+26
-16
lines changed

jsonschema-core.md

Lines changed: 26 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1269,7 +1269,7 @@ desired to identify the object containing the `$ref` in the second
12691269
Due to the potential break in functionality described above, the behavior for
12701270
using JSON Pointer fragments that point to or cross a resource boundary is
12711271
undefined. Schema authors SHOULD NOT rely on such IRIs, as using them may
1272-
reduce interoperability.
1272+
reduce interoperability.[^8]
12731273

12741274
[^8]: This is to avoid requiring implementations to keep track of a whole stack
12751275
of possible base IRIs and JSON Pointer fragments for each, given that all but
@@ -2194,35 +2194,42 @@ name fragment identifiers.
21942194
}
21952195
```
21962196

2197-
The schemas at the following IRI-encoded [JSON Pointers](#rfc6901) (relative to
2198-
the root schema) have the following base IRIs, and are identifiable by any
2199-
listed IRI in accordance with {{fragments}} and {{embedded}} above.
2197+
The schemas at the following locations (indicated by plain
2198+
[JSON Pointers](#rfc6901) relative to the root document) have the following base
2199+
IRIs, and are identifiable by any listed IRI in accordance with {{fragments}}
2200+
and {{embedded}} above.
22002201

2201-
`#` (document root): canonical (and base) IRI: `https://example.com/root.json`
2202+
Document root:
2203+
- canonical (and base) IRI: `https://example.com/root.json`
22022204
- canonical resource IRI plus pointer fragment: `https://example.com/root.json#`
22032205

2204-
`#/$defs/A`: base IRI: `https://example.com/root.json`
2206+
Document location `/$defs/A`:
2207+
- base IRI: `https://example.com/root.json`
22052208
- canonical resource IRI plus plain fragment:
22062209
`https://example.com/root.json#foo`
22072210
- canonical resource IRI plus pointer fragment:
22082211
`https://example.com/root.json#/$defs/A`
22092212

2210-
`#/$defs/B`: canonical (and base) `IRI: https://example.com/other.json`
2213+
Document location `/$defs/B`:
2214+
- canonical (and base) `IRI: https://example.com/other.json`
22112215
- canonical resource IRI plus pointer fragment:
22122216
`https://example.com/other.json#`
22132217

2214-
`#/$defs/B/$defs/X`: base IRI: `https://example.com/other.json`
2218+
Document location `/$defs/B/$defs/X`:
2219+
- base IRI: `https://example.com/other.json`
22152220
- canonical resource IRI plus plain fragment:
22162221
`https://example.com/other.json#bar`
22172222
- canonical resource IRI plus pointer fragment:
22182223
`https://example.com/other.json#/$defs/X`
22192224

2220-
`#/$defs/B/$defs/Y`: canonical (and base) IRI:
2225+
Document location `/$defs/B/$defs/Y`:
2226+
- canonical (and base) IRI:
22212227
`https://example.com/t/inner.json`
22222228
- canonical IRI plus plain fragment: `https://example.com/t/inner.json#bar`
22232229
- canonical IRI plus pointer fragment: `https://example.com/t/inner.json#`
22242230

2225-
`#/$defs/C`: canonical (and base) IRI:
2231+
Document location `/$defs/C`:
2232+
- canonical (and base) IRI:
22262233
`urn:uuid:ee564b8a-7a87-4125-8c96-e9f123d6766f`
22272234
- canonical IRI plus pointer fragment:
22282235
`urn:uuid:ee564b8a-7a87-4125-8c96-e9f123d6766f#`
@@ -2232,28 +2239,31 @@ rather, the base IRI used (as part of the full IRI with any fragment) is what
22322239
determines the canonical nature of the resulting full IRI.[^18]
22332240

22342241
[^18]: Multiple "canonical" IRIs? We Acknowledge this is potentially confusing,
2235-
and direct you to read the CREF located in the [JSON Pointer fragments and
2236-
embedded schema resources](#embedded) section for further comments.
2242+
and direct you to read the CREF located in {{#embedded}} for further comments.
22372243

22382244
While the following IRIs do correctly indicate specific schemas, per the reasons
22392245
outlined in {{embedded}}, they are to be avoided:
22402246

2241-
`#/$defs/B`: canonical (and base) `IRI: https://example.com/other.json`
2247+
Document location `/$defs/B`:
2248+
- canonical (and base) `IRI: https://example.com/other.json`
22422249
- base IRI of enclosing (root.json) resource plus fragment:
22432250
`https://example.com/root.json#/$defs/B`
22442251

2245-
`#/$defs/B/$defs/X`: base IRI: `https://example.com/other.json`
2252+
Document location `/$defs/B/$defs/X`:
2253+
- base IRI: `https://example.com/other.json`
22462254
- base IRI of enclosing (root.json) resource plus fragment:
22472255
`https://example.com/root.json#/$defs/B/$defs/X`
22482256

2249-
`#/$defs/B/$defs/Y`: canonical (and base) IRI:
2257+
Document location `/$defs/B/$defs/Y`:
2258+
- canonical (and base) IRI:
22502259
`https://example.com/t/inner.json`
22512260
- base IRI of enclosing (other.json) resource plus fragment:
22522261
`https://example.com/other.json#/$defs/Y`
22532262
- base IRI of enclosing (root.json) resource plus fragment:
22542263
`https://example.com/root.json#/$defs/B/$defs/Y`
22552264

2256-
`#/$defs/C`: canonical (and base) IRI:
2265+
Document location `/$defs/C`:
2266+
- canonical (and base) IRI:
22572267
`urn:uuid:ee564b8a-7a87-4125-8c96-e9f123d6766f`
22582268
- base IRI of enclosing (root.json) resource plus fragment:
22592269
`https://example.com/root.json#/$defs/C`

0 commit comments

Comments
 (0)