Skip to content
This repository has been archived by the owner on Jul 30, 2019. It is now read-only.

restrict custom attributes to data-* ? #1337

Closed
chaals opened this issue Apr 5, 2018 · 4 comments
Closed

restrict custom attributes to data-* ? #1337

chaals opened this issue Apr 5, 2018 · 4 comments
Labels

Comments

@chaals
Copy link
Collaborator

chaals commented Apr 5, 2018

See also whatwg/html#2271 and the discussion following https://www.w3.org/2018/03/05-webplat-minutes.html#resolution03

@chaals chaals added the question label Apr 6, 2018
@chaals
Copy link
Collaborator Author

chaals commented Apr 6, 2018

The argument is roughly that we avoid cluttering the web with more attributes that might clash as we extend the platform, but we force developers to choose between their code being valid and helping to meet that goal, and having shorter, more readable and typable attribute names.

I.e. should we insist on e.g. data-new-attribute or data-myns-attribute (allowing namespacing), for maximum extensibility of the platform, or should we allow my-newAttrs for maximum developer comfort?

@chaals
Copy link
Collaborator Author

chaals commented Apr 6, 2018

Unless and until we have a proper custom attributes framework in place, and noting that is something which people continue to want and think they will work on, I strongly favour the restrictive version.

chaals added a commit that referenced this issue Apr 6, 2018
Notes:

Split autonomous and customized built-in elements a bit

This commit includes is=, despite the resolution of #1277

It also presupposes that #1337 is resolved for the more restrictive approach.
siusin pushed a commit that referenced this issue Apr 11, 2018
* initial pieces

Chapters 2-3 normative stuff from the CE spec. Very WiP

* cleaning up syntax

Conversion to bikeshed/linking stuff. Possibly introducing some linking bugs to check when I'm mostly done :S

* first pass syntax conversion

This file will need another round of this, but leaving it for now.

* Commit the element bits of custom elements

Notes:

Split autonomous and customized built-in elements a bit

This commit includes is=, despite the resolution of #1277

It also presupposes that #1337 is resolved for the more restrictive approach.

* at risk, is= in attributes table

Add global/is to the attributes table
Mark it, and customized built-ins, as under consideration for "at risk"

* define is=,

some editorial cleaning in global attributes section

* update intro

custom elements could be considered an extensibility mechanism...

* some thank yous

Certain to have missed people who deserved to be thanked. :(

* thank yous

* update changes

split into the general piece and customized - if Firefox hasn't implemented them yet, they will be at risk for the 5.3 version.

* fix syntax errors

Bikeshed won't build without fixing some errors

* Fix link

* fix link again

* link fix

* update URN link

* Fix link errors

* linking fixes

* Fix last link errors

(of those introduced by this commit)

* linking and grammar fixes

Thank you @prlbr

* tweaks

fixing links, exporting definitions, hopefully fix multipage

* fixes for review

links, typos, ...
@chaals
Copy link
Collaborator Author

chaals commented Apr 25, 2018

In #1343 the restrictive version of this is put in the spec.

@chaals
Copy link
Collaborator Author

chaals commented Apr 25, 2018

Closing.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant