swagger-php icon indicating copy to clipboard operation
swagger-php copied to clipboard

How to use brackets in @SWG\Examples?

Open mvnp opened this issue 6 years ago • 2 comments

I need to load data into information: [{ }, { }, { }, { } ...] on this format but all time I try this, I have a bug. How to show example with an array of objects?

mvnp avatar Aug 20 '20 15:08 mvnp

Please provide a more complete example because your question does not make much sense to me I'm afraid.

Doqnach avatar Aug 20 '20 18:08 Doqnach

@mvnp Take a look here: http://zircote.github.io/swagger-php/Getting-started.html#arrays-and-objects

You do not use brackets but curly brackets, e.g. {{},{},{}} this is the same (and it will be interpreted) as [{},{},{}]

moxival avatar Aug 25 '20 20:08 moxival