summaryrefslogtreecommitdiffstats
path: root/templates/games
diff options
context:
space:
mode:
Diffstat (limited to 'templates/games')
-rw-r--r--templates/games/index.html.template14
-rw-r--r--templates/games/rms.html.template18
2 files changed, 18 insertions, 14 deletions
diff --git a/templates/games/index.html.template b/templates/games/index.html.template
index 917a0c9..f235bd1 100644
--- a/templates/games/index.html.template
+++ b/templates/games/index.html.template
@@ -1,8 +1,10 @@
{{define "head"}}<title>Games</title>{{end}}
-<section>
- <ul>
- <li><a href="/games/pong">Pong</a> (warning: loud)</li>
- <li><a href="/games/rms">RMS shooter</a></li>
- </ul>
-</section>
+{{define "body" -}}
+ <section>
+ <ul>
+ <li><a href="/games/pong">Pong</a> (warning: loud)</li>
+ <li><a href="/games/rms">RMS shooter</a></li>
+ </ul>
+ </section>
+{{- end}}
diff --git a/templates/games/rms.html.template b/templates/games/rms.html.template
index ba00824..9f396fe 100644
--- a/templates/games/rms.html.template
+++ b/templates/games/rms.html.template
@@ -1,10 +1,12 @@
-{{define "head"}}
- <title>RMS shooter</title>
- <script src="/static/games/rms/rms.js" defer></script>
-{{end}}
+{{define "head" -}}
+ <title>RMS shooter</title>
+ <script src="/static/games/rms/rms.js" defer></script>
+{{- end}}
-<img id="sprite-sheet" src="/static/games/rms/sprite-sheet.webp" hidden>
+{{define "body" -}}
+ <img id="sprite-sheet" src="/static/games/rms/sprite-sheet.webp" hidden>
-<section>
- <canvas id="canvas" width="800" height="600"></canvas>
-</section>
+ <section>
+ <canvas id="canvas" width="800" height="600"></canvas>
+ </section>
+{{- end}}