Specify module order manually to work around hugo issues (#3612)

This commit is contained in:
Travis Ralston 2022-01-04 20:29:10 -07:00 committed by GitHub
parent 0ee58100c4
commit 00169abcdb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
36 changed files with 50 additions and 51 deletions

View file

@ -0,0 +1,13 @@
{{/*
This template is used to render a Client-Server API Module. Modules are defined
alongside the `_index.md` for the CS API.
The `name` parameter is the file name without extension.
*/}}
{{ $name := .Params.name }}
{{ $page := .Site.GetPage (path.Join .Page.Dir "modules" (printf "%s%s" $name ".md"))}}
{{ $page.Content }}

View file

@ -1,14 +0,0 @@
{{/*
This template is used to embed module documentation in the client-server API spec.
It searches the site for pages of type "module", sorts them by weight, and
emits the page's rendered content.
*/}}
{{ $modules := where site.Pages "Type" "module" }}
{{ range $modules.ByWeight }}
{{ .Content }}
{{ end }}