You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Tags contain a tag name, giving the element's name. HTML elements all have names that only use ASCII alphanumerics. In the HTML syntax, tag names, even those for foreign elements, may be written with any mix of lower- and uppercase letters that, when converted to all-lowercase, matches the element's tag name; tag names are case-insensitive.
But this does not include custom elements, I'll have to check.
Attributes have a name and a value. Attribute names must consist of one or more characters other than controls, U+0020 SPACE, U+0022 ("), U+0027 ('), U+003E (>), U+002F (/), U+003D (=), and noncharacters. In the HTML syntax, attribute names, even those for foreign elements, may be written with any mix of ASCII lower and ASCII upper alphas.
There could be two ways to implement this check:
Return an error on encountering an invalid element or attribute name.
Strip invalid characters from element and attribute names. (But the remaining characters may still not be a valid name if the original name only consists of invalid characters.)
I'm leaning towards (1) after I figure out what characters exactly are allowed in element names.
The text was updated successfully, but these errors were encountered:
(In these two cases, where the invalid value is a literal, this should be a compile error. The runtime error would be when the element or attribute name is from a runtime value.)
Follow up to #28, which has been fixed now.
prints:
This one is more tricky to fix since element and attribute names cannot be just escaped - they have a set of valid characters.
Element names: ref
But this does not include custom elements, I'll have to check.
Attribute names: ref
There could be two ways to implement this check:
I'm leaning towards (1) after I figure out what characters exactly are allowed in element names.
The text was updated successfully, but these errors were encountered: