Please test for double quote as well. Currently double quote handling is buggy.

tpl/layout/base.html
<meta charset="utf-8" />

=>

_buffer.WriteString("\n<!DOCTYPE html>\n<html>\n<head>\n<meta charset="utf-8" />\n")

It should be 

_buffer.WriteString("\n<!DOCTYPE html>\n<html>\n<head>\n<meta charset=\"utf-8\" />\n")