Skip to content

go/doc: add ToMarkdown #34875

Closed
Closed
@JAicewizard

Description

@JAicewizard

Recently gopls added markdown output for markdown comments, the implementation is basically a copy of go/doc/comment.go replacing some things with markdown instead of html.
If go/doc was more flexible this would have been less of a copy paste. These should be a interface which can be used to create custom formatters. In this way packages that need backwards compatibility with older go stdlibs can create a formatter and use this with older versions of go. The type implementing this can be copy pasted into go/doc/comment.go(or vice versa).

I am willing to implement this together with porting the gopls markdown implementation to go/doc

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    Accepted

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions