Skip to content
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

CSSUnparsedValue/forEach - WebIDL spec URL #11426

Closed
dontcallmedom opened this issue Jul 8, 2021 · 3 comments · Fixed by #11522
Closed

CSSUnparsedValue/forEach - WebIDL spec URL #11426

dontcallmedom opened this issue Jul 8, 2021 · 3 comments · Fixed by #11522
Labels
data:api 🐇 Compat data for Web APIs. https://developer.mozilla.org/docs/Web/API

Comments

@dontcallmedom
Copy link
Contributor

the entry for CSSUnparsedValue/forEach (and other interface members derived from its iterable declaration) is associated with the WebIDL spec of iterable.

While there is some truth to it, it means WebIDL is listed as the relevant spec on https://developer.mozilla.org/en-US/docs/Web/API/CSSUnparsedValue/forEach which I don't think is particularly useful. https://drafts.css-houdini.org/css-typed-om/#cssunparsedvalue would likely be a more useful reference.

I haven't checked if this is specific to this interface, or a more general issue with iterators.

(there may also be a discussion to be had whether duplicating the content documentation of forEach et al for all the interfaces that are iterators is worth the maintenance cost, but that's probably for mdn/content; and again, I haven't checked whether that's a generic thing or not - this issue was prompted by reviewing mdn/content#2462)

@queengooborg queengooborg added the data:api 🐇 Compat data for Web APIs. https://developer.mozilla.org/docs/Web/API label Jul 8, 2021
@foolip
Copy link
Collaborator

foolip commented Jul 14, 2021

I just filed #11519 which is effectively a dupe. What I wrote:

In #10976 (comment) @sideshowbarker describes the current practice in BCD:

For interfaces with maplike declarations, we do consistently have a spec_url for those, which is the same URL in every case: https://heycam.github.io/webidl/#idl-maplike
(and for interfaces with iterable declarations, we do consistently have a spec_url for those, which is the same URL in every case: https://heycam.github.io/webidl/#idl-iterable)

I'm not sure where these URLs will end up, but I think showing them to web developers will not be useful. Linking to https://heycam.github.io/webidl/#idl-iterable to for a forEach method is a bit like linking to https://heycam.github.io/webidl/#idl-interfaces to any interface, in that it explains how a certain piece of Web IDL syntax ended up producing the JS objects that the web developer can see, but says nothing useful about the specific API.

It is unfortunately the case that specs that use these Web IDL declarations won't provide anything useful to link to, but I would argue no spec_url is then more appropriate.

@sideshowbarker
Copy link
Collaborator

sideshowbarker commented Jul 14, 2021

I would be fine with removing the spec_url for this case and for all the other cases where the spec_url value is https://heycam.github.io/webidl/#idl-maplike.

I would very much not support replacing the spec_url value with a link to an IDL declaration such as https://drafts.css-houdini.org/css-typed-om/#cssunparsedvalue — nor in general with linking to any IDL blocks for any of these cases. That would be much less helpful for developers than linking to the prose of the WebIDL spec.

@foolip
Copy link
Collaborator

foolip commented Jul 14, 2021

I've sent #11522 to remove the URLs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
data:api 🐇 Compat data for Web APIs. https://developer.mozilla.org/docs/Web/API
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants