-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Are all uses of the title
attribute discouraged?
#10875
Comments
I think the note is accurate? As in, it seems fine to use it if the information is otherwise available or not that important, but you cannot rely on the end user having access to it. The most commonly used device to access the web does generally not expose |
I think there are some valid use cases for the
|
What about adding this then: "Relying on the title attribute to provide additional information about an element via a user-agent tooltip is currently discouraged as many user agents do not expose the attribute in an accessible manner as required by this specification". This would make the note clearer to me. Reading this, I know when the title attribute is discouraged, and when it isn't. |
What is the issue with the HTML Standard?
The
title
attribute section contains this note:(It also appears a few other places, such as the requirements for providing text alternatives section.)
Do the editors wish to discourage authors from all uses of the
title
attribute?As someone working on documentation for the web platform, I don't know how to describe the condition of this feature. Unlike other features in this and other web platform specifications, it's unclear if the
title
attribute is under the umbrella of things that the spec wishes for authors to not use in new web content.There's an additional layer of uncertainty here, given by "currently." I took this to mean the note was anticipating changes, except it's 12 years old (commit). I couldn't find any open issues discussing the
title
attribute.It'd be helpful if the spec could be rather more specific in this note, both with respect to when the note applies and to whom. I don't have an opinion about what the actual position of the editors ought to be, but I'd like to know what it is.
To resolve this, I'd expect the note to say something along the lines of "Authors should not use the
title
attribute because…. Authors should instead…" or "Authors should not use thetitle
attribute unless…" depending on what y'all think the answer is. Or if it's really serious, to listtitle
amongst the obsolete features.For background, this came came up while trying to summarize feature information for developers in the web-features project: web-platform-dx/web-features#2461.
This is my first time filing an issue with WHATWG, so please let me know if I've missed anything. And thank you for considering this issue.
The text was updated successfully, but these errors were encountered: