Added site to this repo and Gitlab to build it

This commit is contained in:
Leon Mika 2025-10-26 09:25:36 +11:00
parent 8dafa6fa8f
commit c474b18232
50 changed files with 1812 additions and 1 deletions

View file

@ -0,0 +1,3 @@
{{- $options := dict "targetPath" "js/bundle.js" -}}
{{- $jsBundle := resources.Get "js/index.js" | js.Build $options | resources.Minify | fingerprint -}}
<script src="{{ $jsBundle.RelPermalink | absURL }}" defer></script>

View file

@ -0,0 +1 @@
<script src="https://tinylytics.app/embed/vgYK9BZh7G14oSKuW2wR.js" defer></script>

View file

@ -0,0 +1,62 @@
{{ define "main" }}
<article class="markdown">
{{ partial "docs/post-meta" . }}
{{- .Content -}}
<!-- API Data -->
{{ range sort $.Site.Data.scriptmods }}
<section>
{{ if eq .type "type" }}
<h2 id="type-{{.module}}">
Type: {{ .module }}
<a class="anchor" href="#type-{{.module}}">#</a>
</h2>
{{ else }}
<h2 id="module-{{.module}}">
Module: {{ .module }}
<a class="anchor" href="#module-{{.module}}">#</a>
</h2>
{{ end }}
{{ $.RenderString .docs }}
{{ $moduleName := .module }}
{{ range sort .symbols "name" }}
<h3 id="{{$moduleName}}-{{.name}}">
{{$moduleName}}.{{ .name }}
<a class="anchor" href="#{{$moduleName}}-{{.name}}">#</a>
</h3>
<pre><code>{{ .syntax }}</code></pre>
{{ $.RenderString .docs }}
{{if .example}}
<h4>Example</h4>
<pre><code>{{ .example }}</code></pre>
{{end}}
{{ end }}
</section>
{{end}}
</article>
{{ end }}
{{ define "toc" }}
<nav id="TableOfContents">
<ul>
{{ range sort $.Site.Data.scriptmods }}
{{ if eq .type "type" }}
<li><a href="#type-{{.module}}">{{ .module }}</a></li>
{{ else }}
<li><a href="#module-{{.module}}">{{ .module }}</a></li>
{{ end }}
{{/*
<ul>
{{ $moduleName := .module }}
{{ range sort .symbols "name" }}
<li><a href="#{{$moduleName}}-{{.name}}">{{ .name }}</a></li>
{{ end }}
</ul>
*/}}
{{ end }}
</ul>
</nav>
{{ end }}