Alternative the master branch at https://github.com/nvx/protoc-gen-doc/tree/master has this and some other fixes to unit tests and version bumps (I note the version of golang.org/x/crypto in the go.mod has outstanding CVEs, unit tests fail on Windows, and it's using a long out of support version of Go) and could be merged instead.
Adds support for buf validate https://github.com/bufbuild/protovalidate
Alternative the master branch at https://github.com/nvx/protoc-gen-doc/tree/master has this and some other fixes to unit tests and version bumps (I note the version of golang.org/x/crypto in the go.mod has outstanding CVEs, unit tests fail on Windows, and it's using a long out of support version of Go) and could be merged instead.