From a600e96bd6c9be12c1a84f5aded5af853627f286 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Standa=20Luke=C5=A1?= Date: Sat, 7 Sep 2024 17:45:52 +0200 Subject: [PATCH] HtmlWriter: remove upper attribute warning, as it is redundant The same warning is emitted compile-time, which makes this one redundant. Moreover, the compile-time warning includes smarter checks, and allows certain cases of uppercase attributes (in prefixed capabilities) --- src/Framework/Framework/Controls/HtmlWriter.cs | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/Framework/Framework/Controls/HtmlWriter.cs b/src/Framework/Framework/Controls/HtmlWriter.cs index 80cbce74c..94e7e1ac6 100644 --- a/src/Framework/Framework/Controls/HtmlWriter.cs +++ b/src/Framework/Framework/Controls/HtmlWriter.cs @@ -322,11 +322,6 @@ private void WriteAttrWithTransformers(string name, string attributeName, string { WriteHtmlAttribute(attributeName, attributeValue); } - - if (this.enableWarnings && char.IsUpper(attributeName[0])) - { - Warn($"{attributeName} is used as an HTML attribute on element {name}, but it starts with an uppercase letter. Did you intent to use a DotVVM property instead? To silence this warning, just use all lowercase letters for standard HTML attributes."); - } } private string ConvertHtmlAttributeValue(object value)