asciidoctor-godoc

An Asciidoctor extension to add a 'godoc' macro

MIT License

Downloads
705
Stars
0
Committers
1

= asciidoctor-godoc

image:https://badge.fury.io/rb/asciidoctor-godoc.svg["Gem Version", link="https://badge.fury.io/rb/asciidoctor-godoc"]

An asciidoctor extension that adds support for a godoc macro. The macro allows you to reference types and functions in a Go package by name, and links to their documentation on https://pkg.go.dev[pkg.go.dev].

For example, given the following:

.Input
[,asciidoctor]

The godoc:http[] package provides
godoc:net/http#ServeMux[] for request routing.
Register zero or more godoc:net/http#Handler[handlers] against it,
and specify it as a godoc:net/http#Server.Handler[]
in your server's configuration.

.Output
[%collapsible]

The {url-godoc}/http[http] package provides
{url-godoc}/net/http#ServeMux[http.ServeMux] for request routing.
Register zero or more {url-godoc}/net/http#Handler[handlers] against it,
and specify it as a {url-godoc}/net/http#Server.Handler[Server.Handler]
in your server's configuration.

See https://abhinav.github.io/asciidoctor-godoc/ for complete documentation.