Do you want to request a feature or report a bug?
Report a bug.
What is the current behavior?
The HTMLDOMPropertyConfig object includes an icon property in a section title Standard Properties, but icon isn’t an attribute supported by any standard HTML element.
icon is not included in the HTML4 or HTML5 specs:
List of HTML4 attributes
List of HTML5 attributes
Mozilla Developer Network includes icon in its list of attributes, but specifies the only element to use icon is the obsolete <command> element. <command> isn’t supported in any desktop or mobile browser.
What is the expected behavior?
The icon property might be better placed in the section titled Non-standard Properties, or removed altogether. The documentation for HTML attributes could omit icon too.
I encountered this issue when working with TypeScript, and I opened an issue about the React type definition at DefinitelyTyped/DefinitelyTyped#10467. Because React itself includes icon, custom interfaces which extend DefinitelyTyped’s React.HTMLAttributes cannot include a non-string icon property.
Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React?
icon was added in a React 0.4.0 alpha in 2013: 203dba2. The commit message mentions mostly this was to better support some HTML5 stuff—it’s possible icon was part of a draft of the HTML5 standard at the time, but was omitted in the final spec.
Do you want to request a feature or report a bug?
Report a bug.
What is the current behavior?
The
HTMLDOMPropertyConfigobject includes aniconproperty in a section titleStandard Properties, buticonisn’t an attribute supported by any standard HTML element.iconis not included in the HTML4 or HTML5 specs:List of HTML4 attributes
List of HTML5 attributes
Mozilla Developer Network includes
iconin its list of attributes, but specifies the only element to useiconis the obsolete<command>element.<command>isn’t supported in any desktop or mobile browser.What is the expected behavior?
The
iconproperty might be better placed in the section titledNon-standard Properties, or removed altogether. The documentation for HTML attributes could omiticontoo.I encountered this issue when working with TypeScript, and I opened an issue about the React type definition at DefinitelyTyped/DefinitelyTyped#10467. Because React itself includes
icon, custom interfaces which extend DefinitelyTyped’sReact.HTMLAttributescannot include a non-stringiconproperty.Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React?
iconwas added in a React 0.4.0 alpha in 2013: 203dba2. The commit message mentionsmostly this was to better support some HTML5 stuff—it’s possibleiconwas part of a draft of the HTML5 standard at the time, but was omitted in the final spec.