Results 231 comments of Luke Frisken

The would also be good to have for response and request bodies.

The json schema generated for this struct is: ```json { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Bar", "type": "object", "required": [ "foo" ], "properties": { "foo": { "type": "array", "items": [ { "type":...

Perhaps at least we could improve the error message?

It seems like https://github.com/juhaku/utoipa/issues/180 could be used as a workaround?

Or just renaming the type to `Foo` but I guess that might upset some clippy lints somewhere

I think there's not really any other way, it seems like we do need something like the proposed `as` syntax. As a side note, I'm not using the `#[openapi(` macro...

@RemiKalbe Here's my version of the `as` syntax: ```rust macro_rules! component { ($c:path) => { (stringify!($c).replace("::", "."), ::component()) }; ($c:path as $p:path) => { (stringify!($p).replace("::", "."), ::component()) }; } ```...

@juhaku, I was thinking that perhaps some people might not want to pay the compile time cost of serializing the example for something big, but then again, I guess that's...

perhaps instead a `json_no_validate!()` attribute can be added later if required :slightly_smiling_face:

> But again when people define the example with json!() attribute it will be serialized with serde_json already when it will be added to the OpenAPI spec. That's true, but...