carlos / todomvc-bakeoff Public

Clone
git clone https://amadan.net/carlos/todomvc-bakeoff

Plain git — no account needed to clone.

Download

Download this file

1<!doctype html>
2<html lang="en">
3<head>
4<meta charset="utf-8">
5<meta name="viewport" content="width=device-width, initial-scale=1">
6<title>{{t .Copy "page.title"}}</title>
7{{template "css"}}
8</head>
9<body>
10<main>
11<h1>{{cp $.Copy "page.title" $.Preview}}</h1>
12{{md .Copy "page.intro"}}
13<p><a href="writeup.html">{{cp $.Copy "page.writeup_link" $.Preview}}</a></p>
14
15<h2>{{cp $.Copy "findings.heading" $.Preview}}</h2>
16{{md .Copy "findings.body"}}
17
18<h2>{{cp $.Copy "glance.heading" $.Preview}}</h2>
19<div class="card scroll">
20<table>
21<thead><tr><th>{{cp $.Copy "glance.col.setup" $.Preview}}</th><th>{{cp $.Copy "glance.col.tests" $.Preview}}</th><th>{{cp $.Copy "glance.col.first_byte" $.Preview}}</th><th>{{cp $.Copy "glance.col.wake" $.Preview}}</th><th>{{cp $.Copy "glance.col.reads" $.Preview}}</th><th>{{cp $.Copy "glance.col.binary" $.Preview}}</th><th>{{cp $.Copy "glance.col.build" $.Preview}}</th><th>{{cp $.Copy "glance.col.lines" $.Preview}}</th><th>{{cp $.Copy "glance.col.deps" $.Preview}}</th><th>{{cp $.Copy "glance.col.cost" $.Preview}}</th><th>{{cp $.Copy "glance.col.readability" $.Preview}}</th></tr></thead>
22<tbody>
23{{- range .Results}}
24{{- if live .}}
25<tr><td>{{.Language}}</td>
26<td>{{.BehaviourJSOn.Passed}}/{{ran .BehaviourJSOn}} · {{.BehaviourJSOff.Passed}}/{{ran .BehaviourJSOff}}</td>
27<td>{{ms .TTFBEmpty.P50}}</td><td>{{ms (wake .)}}</td><td>{{num (peak . "read")}}</td>
28<td>{{mb (float .Build.Bytes)}}</td><td>{{secs .Build.ColdSeconds}} / {{secs .Build.EditSeconds}}</td>
29<td>{{loc .Code}}</td><td>{{.Code.Deps}}</td><td>{{usd (total .).CostUSD}}</td><td>{{.Readability.Overall}}/10</td></tr>
30{{- else}}
31<tr class="blocked"><td>{{.Language}}</td><td colspan="10">{{.Status}}</td></tr>
32{{- end}}
33{{- end}}
34</tbody>
35</table>
36</div>
37
38{{range .Charts}}{{$ch := .}}
39<div class="card">
40<h3>{{if $.Preview}}<span data-copy="chart.{{.ID}}.title">{{.Title}}</span>{{else}}{{.Title}}{{end}}</h3>
41<p class="note">{{if $.Preview}}<span data-copy="chart.{{.ID}}.note">{{.Note}}</span>{{else}}{{.Note}}{{end}}</p>
42{{.SVG}}
43{{- if .HasParts}}
44<ul class="legend">{{range $i, $p := .Parts}}<li style="--k: var(--s{{inc $i}})">{{if $.Preview}}<span data-copy="{{index $ch.LegendIDs $i}}">{{$p}}</span>{{else}}{{$p}}{{end}}</li>{{end}}</ul>
45<div class="scroll"><table><thead><tr><th>{{cp $.Copy "glance.col.setup" $.Preview}}</th>{{range .Parts}}<th>{{.}}</th>{{end}}</tr></thead><tbody>
46{{- range .Rows}}{{if .Parts}}<tr><td>{{.Language}}</td>{{range .Parts}}<td>{{num .}}</td>{{end}}</tr>{{end}}{{end}}
47</tbody></table></div>
48{{- end}}
49</div>
50{{end}}
51
52<h2>{{cp $.Copy "apps.heading" $.Preview}}</h2>
53{{range .Results}}
54<div class="card">
55<h3>{{.Language}}</h3>
56<dl>
57{{- if .URL}}<dt>{{cp $.Copy "apps.live" $.Preview}}</dt><dd><a href="{{.URL}}">{{.URL}}</a></dd>{{end}}
58{{- if .Source}}<dt>{{cp $.Copy "apps.source" $.Preview}}</dt><dd><a href="{{.Source}}">{{.Source}}</a></dd>{{end}}
59{{- if opt $.Copy (printf "stack.%s" .Slug)}}<dt>{{cp $.Copy "apps.stack" $.Preview}}</dt><dd>{{cp $.Copy (printf "stack.%s" .Slug) $.Preview}}</dd>{{end}}
60{{- if .Readability.Notes}}<dt>{{cp $.Copy "apps.readability" $.Preview}}</dt><dd>{{.Readability.Notes}}</dd>{{end}}
61{{- if .ReviewFindings}}<dt>{{cp $.Copy "apps.unfixed" $.Preview}}</dt><dd><ul>{{range .ReviewFindings}}<li>{{.}}</li>{{end}}</ul></dd>{{end}}
62{{- if opt $.Copy (printf "note.%s" .Slug)}}<dt>{{cp $.Copy "apps.note" $.Preview}}</dt><dd>{{cp $.Copy (printf "note.%s" .Slug) $.Preview}}</dd>{{end}}
63</dl>
64</div>
65{{end}}
66
67<h2>{{cp $.Copy "method.heading" $.Preview}}</h2>
68{{md .Copy "method.body"}}
69<h2>{{cp $.Copy "caveats.heading" $.Preview}}</h2>
70{{md .Copy "caveats.body"}}
71</main>
72</body>
73</html>
74