a-poor / a-poor/vhttp

Add `proto` validators

Open
#4 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
2
Forks
1
PR merge metrics
No merged PRs in 30d

Description

Add [ProtoValidator](https://pkg.go.dev/github.com/a-poor/vhttp#ProtoValidator) functions.

`ProtoValidator` functions implements both the [RequestValidator](https://pkg.go.dev/github.com/a-poor/vhttp#RequestValidator) and [ResponseValidator](https://pkg.go.dev/github.com/a-poor/vhttp#ResponseValidator) interfaces and have the following signature...

```go
type ProtoValidator func(string) error
```

...where the argument is the `.Proto` attribute for either the [http.Request](https://pkg.go.dev/net/http#Request) or [http.Response](https://pkg.go.dev/net/http#Response), depending on how it's used.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.