all repos — honk @ 07351e03551fe7c6d243e087542fd1f277281bd2

my fork of honk

move scripting up so it's available on partially loaded pages
Ted Unangst tedu@tedunangst.com
Wed, 29 Jan 2020 21:06:47 -0500
commit

07351e03551fe7c6d243e087542fd1f277281bd2

parent

adc018a21387b12f9b488144825369a1119e3df1

1 files changed, 11 insertions(+), 11 deletions(-)

jump to
M views/honkpage.htmlviews/honkpage.html

@@ -18,17 +18,6 @@ <p><button onclick="refreshhonks(this)">refresh</button><span></span>

<button onclick="oldestnewest(this)">scroll down</button> </div> {{ end }} -<div id="honksonpage"> -<div> -{{ $BonkCSRF := .HonkCSRF }} -{{ $IsPreview := .IsPreview }} -{{ $MapLink := .MapLink }} -{{ range .Honks }} -{{ template "honk.html" map "Honk" . "MapLink" $MapLink "BonkCSRF" $BonkCSRF "IsPreview" $IsPreview }} -{{ end }} -</div> -</div> -</main> {{ if .HonkCSRF }} <script> var csrftoken = {{ .HonkCSRF }}

@@ -42,3 +31,14 @@

</script> <script src="/honkpage.js{{ .JSParam }}"></script> {{ end }} +<div id="honksonpage"> +<div> +{{ $BonkCSRF := .HonkCSRF }} +{{ $IsPreview := .IsPreview }} +{{ $MapLink := .MapLink }} +{{ range .Honks }} +{{ template "honk.html" map "Honk" . "MapLink" $MapLink "BonkCSRF" $BonkCSRF "IsPreview" $IsPreview }} +{{ end }} +</div> +</div> +</main>