github.com/1aal/kubeblocks@v0.0.0-20231107070852-e1c03e598921/hack/docgen/api/template/pkg.tpl (about)

     1  {{ define "packages" }}
     2  
     3  ---
     4  title: {{ .apiName | toTitle }} API Reference
     5  description: {{ .apiName | toTitle }} API Reference
     6  keywords: [{{ .apiName }}, api]
     7  sidebar_position: {{ .filerOrder }}
     8  sidebar_label: {{ .apiName | toTitle }}
     9  ---
    10  <br />
    11  
    12  {{ with .packages}}
    13  
    14  <p>Packages:</p>
    15  <ul>
    16      {{ range . }}
    17      <li>
    18          <a href="#{{- packageAnchorID . -}}">{{ packageDisplayName . }}</a>
    19      </li>
    20      {{ end }}
    21  </ul>
    22  {{ end}}
    23  
    24  {{ range .packages }}
    25      <h2 id="{{- packageAnchorID . -}}">
    26          {{- packageDisplayName . -}}
    27      </h2>
    28  
    29      {{ with (index .GoPackages 0 )}}
    30          {{ with .DocComments }}
    31          <div>
    32              {{ safe (renderComments .) }}
    33          </div>
    34          {{ end }}
    35      {{ end }}
    36  
    37      Resource Types:
    38      <ul>
    39      {{- range (visibleTypes (sortedTypes .Types)) -}}
    40          {{ if isExportedType . -}}
    41          <li>
    42              <a href="{{ linkForType . }}">{{ typeDisplayName . }}</a>
    43          </li>
    44          {{- end }}
    45      {{- end -}}
    46      </ul>
    47  
    48      {{ range (visibleTypes (sortedTypes .Types))}}
    49          {{ template "type" .  }}
    50      {{ end }}
    51      <hr/>
    52  {{ end }}
    53  
    54  <p><em>
    55      Generated with <code>gen-crd-api-reference-docs</code>
    56  </em></p>
    57  
    58  {{ end }}