all repos — homestead @ a3ad47b3eb74f281df9f5d3c733fd60c56f5c462

Code for my website

fix static file access in docker

Alan Pearce
commit

a3ad47b3eb74f281df9f5d3c733fd60c56f5c462

parent

fb8cdcbd48543e800aa0f69b9264a09abef86d75

1 file changed, 4 insertions(+), 4 deletions(-)

changed files
M templates/page.templtemplates/page.templ
@@ -9,15 +9,15 @@ "net/url"
) var ( - css string + CSS string ) -func Setup() { +func init() { bytes, err := fs.ReadFile(Files, "style.css") if err != nil { panic(err) } - css = string(bytes) + CSS = string(bytes) } type PageSettings struct {
@@ -52,7 +52,7 @@ <meta charset="utf-8"/>
<meta name="viewport" content="width=device-width, initial-scale=1.0"/> <title>{ page.Title }</title> <link rel="alternate" type="application/atom+xml" title={ site.Title } href="/atom.xml"/> - @style(css) + @style(CSS) </head> <body { page.BodyAttrs... }> <a class="skip" href="#main">Skip to main content</a>