layout.gohtml 612 B

12345678910111213141516171819202122232425
  1. {{ define "layout.html" }}
  2. <!DOCTYPE html>
  3. <html lang="">
  4. <head>
  5. <title>Contact App</title>
  6. <link rel="stylesheet" href="/static/missing.min.css">
  7. <link rel="stylesheet" href="/static/site.css">
  8. </head>
  9. <body>
  10. <main>
  11. <header>
  12. <h1>
  13. <all-caps>contacts.app</all-caps>
  14. <sub-title>A demo contacts application</sub-title>
  15. </h1>
  16. {{ $flash := flash }}
  17. {{ if ne $flash "" }}
  18. <div class="flash">{{ $flash }}</div>
  19. {{ end }}
  20. </header>
  21. {{ block "content" . }}Default content{{ end }}
  22. </main>
  23. </body>
  24. </html>
  25. {{ end }}