prettier html

This commit is contained in:
Ted Unangst 2020-01-25 19:06:03 -05:00
parent 49972dd5fd
commit 2b211ca480
1 changed files with 4 additions and 4 deletions

View File

@ -109,20 +109,20 @@ func markitzero(s string) string {
} }
switch cell { switch cell {
case ":---": case ":---":
alignments[i] = `style="text-align: left"` alignments[i] = ` style="text-align: left"`
continue continue
case ":---:": case ":---:":
alignments[i] = `style="text-align: center"` alignments[i] = ` style="text-align: center"`
continue continue
case "---:": case "---:":
alignments[i] = `style="text-align: right"` alignments[i] = ` style="text-align: right"`
continue continue
} }
if !hastr { if !hastr {
r.WriteString("<tr>") r.WriteString("<tr>")
hastr = true hastr = true
} }
fmt.Fprintf(&r, "<td %s>", alignments[i]) fmt.Fprintf(&r, "<td%s>", alignments[i])
r.WriteString(cell) r.WriteString(cell)
} }
} }