You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 31c2091
Browse filesBrowse the repository at this point in the historyBrowse files
docs(json-schema): document Format enum members and Json.value
Documents all 18 members of the `Format` enum and the `value" property of
`Json`.
Also escapes the `@extension` reference in the `Json` doc comment: without
backticks the doc parser reads it as a tag and silently truncates the rest
of the description.
Prerequisite for #1229 and #2090.
/** A date and time, as defined by the `date-time` production in [RFC 3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6). */
142
143
dateTime:"date-time",
144
+
145
+
/** A calendar date, as defined by the `full-date` production in [RFC 3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6). */
143
146
date:"date",
147
+
148
+
/** A time of day, as defined by the `full-time` production in [RFC 3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6). */
144
149
time:"time",
150
+
151
+
/** An ISO 8601 duration such as `P3DT4H5M`, as defined by the `duration` production in [RFC 3339, appendix A](https://datatracker.ietf.org/doc/html/rfc3339#appendix-A). */
145
152
duration:"duration",
153
+
154
+
/** An email address, as defined by the `addr-spec` production in [RFC 5322](https://datatracker.ietf.org/doc/html/rfc5322#section-3.4.1). */
146
155
email:"email",
156
+
157
+
/** An internationalized email address, as defined by [RFC 6531](https://datatracker.ietf.org/doc/html/rfc6531). */
147
158
idnEmail:"idn-email",
159
+
160
+
/** A host name, as defined by [RFC 1123](https://datatracker.ietf.org/doc/html/rfc1123#section-2.1). */
148
161
hostname:"hostname",
162
+
163
+
/** An internationalized host name, as defined by [RFC 5890](https://datatracker.ietf.org/doc/html/rfc5890#section-2.3.2.3). */
149
164
idnHostname:"idn-hostname",
165
+
166
+
/** An IPv4 address, as defined by the `dotted-quad` production in [RFC 2673](https://datatracker.ietf.org/doc/html/rfc2673#section-3.2). */
150
167
ipv4:"ipv4",
168
+
169
+
/** An IPv6 address, as defined by [RFC 4291](https://datatracker.ietf.org/doc/html/rfc4291#section-2.2). */
151
170
ipv6:"ipv6",
171
+
172
+
/** A URI, as defined by [RFC 3986](https://datatracker.ietf.org/doc/html/rfc3986). */
152
173
uri:"uri",
174
+
175
+
/** A URI reference, which may be relative, as defined by [RFC 3986](https://datatracker.ietf.org/doc/html/rfc3986#section-4.1). */
153
176
uriReference:"uri-reference",
177
+
178
+
/** An internationalized resource identifier, as defined by [RFC 3987](https://datatracker.ietf.org/doc/html/rfc3987). */
154
179
iri:"iri",
180
+
181
+
/** An internationalized resource identifier reference, which may be relative, as defined by [RFC 3987](https://datatracker.ietf.org/doc/html/rfc3987). */
155
182
iriReference:"iri-reference",
183
+
184
+
/** A universally unique identifier, as defined by [RFC 4122](https://datatracker.ietf.org/doc/html/rfc4122). */
156
185
uuid:"uuid",
186
+
187
+
/** A JSON pointer, as defined by [RFC 6901](https://datatracker.ietf.org/doc/html/rfc6901). */
157
188
jsonPointer:"json-pointer",
189
+
190
+
/** A relative JSON pointer, as defined by the [relative JSON pointer draft](https://datatracker.ietf.org/doc/html/draft-handrews-relative-json-pointer-01). */
158
191
relativeJsonPointer:"relative-json-pointer",
192
+
193
+
/** A regular expression, as defined by [ECMA-262](https://www.ecma-international.org/publications-and-standards/standards/ecma-262/). */
159
194
regex:"regex",
160
195
}
161
196
162
197
/**
163
198
* Specify that the provided template argument should be emitted as raw JSON or YAML
164
-
* as opposed to a schema. Use in combination with the @extension decorator. For example,
199
+
* as opposed to a schema. Use in combination with the `@extension` decorator. For example,
165
200
* `@extension("x-schema", { x: "value" })` will emit a JSON schema value for `x-schema`,
166
201
* whereas `@extension("x-schema", Json<{x: "value"}>)` will emit the raw JSON code
| dateTime |`"date-time"`|A date and time, as defined by the `date-time` production in [RFC 3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6). |
44
+
| date |`"date"`|A calendar date, as defined by the `full-date` production in [RFC 3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6). |
45
+
| time |`"time"`|A time of day, as defined by the `full-time` production in [RFC 3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6). |
46
+
| duration |`"duration"`|An ISO 8601 duration such as `P3DT4H5M`, as defined by the `duration` production in [RFC 3339, appendix A](https://datatracker.ietf.org/doc/html/rfc3339#appendix-A).|
47
+
| email |`"email"`|An email address, as defined by the `addr-spec` production in [RFC 5322](https://datatracker.ietf.org/doc/html/rfc5322#section-3.4.1). |
48
+
| idnEmail |`"idn-email"`|An internationalized email address, as defined by [RFC 6531](https://datatracker.ietf.org/doc/html/rfc6531). |
49
+
| hostname |`"hostname"`|A host name, as defined by [RFC 1123](https://datatracker.ietf.org/doc/html/rfc1123#section-2.1). |
50
+
| idnHostname |`"idn-hostname"`|An internationalized host name, as defined by [RFC 5890](https://datatracker.ietf.org/doc/html/rfc5890#section-2.3.2.3). |
51
+
| ipv4 |`"ipv4"`|An IPv4 address, as defined by the `dotted-quad` production in [RFC 2673](https://datatracker.ietf.org/doc/html/rfc2673#section-3.2). |
52
+
| ipv6 |`"ipv6"`|An IPv6 address, as defined by [RFC 4291](https://datatracker.ietf.org/doc/html/rfc4291#section-2.2). |
53
+
| uri |`"uri"`|A URI, as defined by [RFC 3986](https://datatracker.ietf.org/doc/html/rfc3986). |
54
+
| uriReference |`"uri-reference"`|A URI reference, which may be relative, as defined by [RFC 3986](https://datatracker.ietf.org/doc/html/rfc3986#section-4.1). |
55
+
| iri |`"iri"`|An internationalized resource identifier, as defined by [RFC 3987](https://datatracker.ietf.org/doc/html/rfc3987). |
56
+
| iriReference |`"iri-reference"`|An internationalized resource identifier reference, which may be relative, as defined by [RFC 3987](https://datatracker.ietf.org/doc/html/rfc3987). |
57
+
| uuid |`"uuid"`|A universally unique identifier, as defined by [RFC 4122](https://datatracker.ietf.org/doc/html/rfc4122). |
58
+
| jsonPointer |`"json-pointer"`|A JSON pointer, as defined by [RFC 6901](https://datatracker.ietf.org/doc/html/rfc6901). |
59
+
| relativeJsonPointer |`"relative-json-pointer"`|A relative JSON pointer, as defined by the [relative JSON pointer draft](https://datatracker.ietf.org/doc/html/draft-handrews-relative-json-pointer-01). |
60
+
| regex |`"regex"`|A regular expression, as defined by [ECMA-262](https://www.ecma-international.org/publications-and-standards/standards/ecma-262/). |
0 commit comments