-
-
Notifications
You must be signed in to change notification settings - Fork 740
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
[Feature] Add more id and data attributes #4779
Comments
I would also love to have data-parent-tag-ids, but that would require more work to expose those. Purpose - to simulate tag namespaces with differently styled tags. |
I'd argue that "value" in every If I were the one adding data attributes, I'd try to add them to the highest-level element that contains the entity whose properties are in the attributes (or the one that best describes the entity, in case it has some boilerplate wrappers). I don't know what the most common approach is - adding data attributes to most specific element or highest-level element. |
Synopsis
Now that the project has fully embraced third-party customization with plugins, please make the markup more accessible to styling. We can start by simply adding
id
anddata
attributes wherever relevant.id attribute
Lets use the
id
attribute to define unique structural sections on each page. This would make styling more accessible (requiring less convoluted selector declarations) and help to determine particular pages.I propose something like a
#pageName-section
format for ID attribute names.data-* attribute
Lets add more
data-*
attributes where relevant. Some of these might be redundant or overly simple, but I'm just spitballing. I welcome people to provide feedback for more pragmatic examplesetc
The text was updated successfully, but these errors were encountered: