Skip to content

Commit 462cfb0

Browse files
committed
doc(faq): transfered questions to README
These discussion threads are valuable, but no longer active. * fixes go-openapi#164 * fixes go-openapi#23 Signed-off-by: Frederic BIDON <[email protected]>
1 parent ed00e71 commit 462cfb0

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

README.md

+23
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,26 @@ The object model for OpenAPI specification documents.
2929
> This [discussion thread](https://github.com/go-openapi/spec/issues/21) relates the full story.
3030
>
3131
> An early attempt to support Swagger 3 may be found at: https://github.com/go-openapi/spec3
32+
33+
* Does the unmarshaling support YAML?
34+
35+
> Not directly. The exposed types know only how to unmarshal from JSON.
36+
>
37+
> In order to load a YAML document as a Swagger spec, you need to use the loaders provided by
38+
> github.com/go-openapi/loads
39+
>
40+
> Take a look at the example there: https://pkg.go.dev/github.com/go-openapi/loads#example-Spec
41+
>
42+
> See also https://github.com/go-openapi/spec/issues/164
43+
44+
* How can I validate a spec?
45+
46+
> Validation is provided by [the validate package](http://github.com/go-openapi/validate)
47+
48+
* Why do we have an `ID` field for `Schema` which is not part of the swagger spec?
49+
50+
> We found jsonschema compatibility more important: since `id` in jsonschema influences
51+
> how `$ref` are resolved.
52+
> This `id` does not conflict with any property named `id`.
53+
>
54+
> See also https://github.com/go-openapi/spec/issues/23

0 commit comments

Comments
 (0)