Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update README.md #881

Merged
merged 1 commit into from
Dec 1, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -137,8 +137,8 @@ func main() {

## Custom content type for body of HTTP request/response

By default, the library parses a body of HTTP request and response
if it has one of the next content types: `"text/plain"` or `"application/json"`.
By default, the library parses a body of the HTTP request and response
if it has one of the following content types: `"text/plain"` or `"application/json"`.
To support other content types you must register decoders for them:

```go
Expand Down Expand Up @@ -173,7 +173,7 @@ func xmlBodyDecoder(body io.Reader, h http.Header, schema *openapi3.SchemaRef, e

## Custom function to check uniqueness of array items

By default, the library check unique items by below predefined function
By default, the library checks unique items using the following predefined function:

```go
func isSliceOfUniqueItems(xs []interface{}) bool {
Expand All @@ -187,8 +187,8 @@ func isSliceOfUniqueItems(xs []interface{}) bool {
}
```

In the predefined function using `json.Marshal` to generate a string can
be used as a map key which is to support check the uniqueness of an array
In the predefined function `json.Marshal` is used to generate a string that can
be used as a map key which is to check the uniqueness of an array
when the array items are objects or arrays. You can register
you own function according to your input data to get better performance:

Expand Down