/// <summary> /// Gets or creates the <see cref="HtmlAttributes"/> stored on a <see cref="MarkdownObject"/> /// </summary> /// <param name="obj">The markdown object.</param> /// <returns>The attached html attributes</returns> public static HtmlAttributes GetAttributes(this IMarkdownObject obj) { var attributes = obj.GetData(Key) as HtmlAttributes; if (attributes == null) { attributes = new HtmlAttributes(); obj.SetAttributes(attributes); } return(attributes); }