TemplateHTMLElement

  1. class TemplateHTMLElement(Element, string form)
  2. alias TemplateHTMLElement(string form) = TemplateHTMLElement!(HTMLElement, form)
    alias TemplateHTMLElement(string form) = TemplateHTMLElement!(HTMLElement, form)

Examples

class MyButton : TemplateHTMLElement!(HTMLElement,
    q{<input type="button" id="%[id%]" value="Click me!">})
{
    this(string id)
    {
        super(id, null, false);
    }
}

auto btn1 = new MyButton("btn1");
assert(btn1.html == q{<input type="button" id="btn1" value="Click me!">});

Meta