Skip to content

proposal: godoc: distinguish type interfaces from other types #23256

Closed
@gertcuykens

Description

@gertcuykens

When your package contains lots of interfaces a user will have a hard time figuring out how to use your package based on the generated godoc's index

Example: https://godoc.org/github.com/nats-io/go-nats-streaming

Golang standard library solves this by including examples on each interface but without a example good luck figuring out how to use instances of the interface

Example: https://golang.org/pkg/net/http/#Hijacker

Proposal:

  1. Distinguish interface types from the other types, color, bold, blinking :P, symbols, extra text,... Anything is fine as long it's more clear what types are interfaces and which one are not

  2. Add the interface function declarations in the index so you have a quick hint what the interface instance is suppose to be doing

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions