Skip to content

Add support for yaml encoding response / decoding request #1252

Description

@Nexucis

Hello,

I didn't see anything relative to an automatic binding when someone a POST request with a YAML body. Same thing when the server send the response with YAML format.

Apart from the stream, we could have the same method that the one for JSON, like that

func (c *context) YAML(code int, i interface{}) (err error) {
}

func (c *context) YAMLPretty(code int, i interface{}, indent string) (err error) {
}

func (c *context) YAMLBlob(code int, b []byte) (err error) {
}

Are you interesting by this idea ? And by the implementation also ?

Thanks for your amazing work :)

Metadata

Metadata

Assignees

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions