1
Vote

Missing HtmlAttributeManager indexer [string, string]

description

You're missing an indexer for the HtmlAttributeManager to allow setting attributes not in the HtmlTextWriterAttribute enum. For example, this will not compile:
        writer
            .Tag(HtmlTextWriterTag.Html, t => t["xmlns", "http://www.w3.org/1999/xhtml"])
Adding this fixes it:
    public HtmlAttributeManager this[string attribute, string value]
    {
        get
        {
            this.Writer.AddAttribute(attribute, value);
            return this;
        }
    }

comments