Re: [whatwg/dom] Provide greater visibility of `implements` relationships? (#249)

It's not an error to have multiple implements statements for the same interface/mixin pairs.  Maybe it should be, within the entire set of IDL fragments that are implemented?

But yes, I think putting the implements statements just after the left-hand-side interface is better.  How about putting all implements statements in a given specification, where the left-hand-side interface is also defined in the same specification, just below the interface definiton.  Then, with some help from Bikeshed, maybe we can automatically generate some informative documentation at the same location, pointing to mixins that other specifications define that apply to the interface.  So reading the DOM spec you would see:

```webidl
interface Document : Node {
  // ...
};

Document implements NonElementParentNode;
Document implements DocumentOrShadowRoot;

// See also: FontFaceSource [FONTLOADING]
// See also: GeometryUtils [GEOMETRY]
```

and perhaps also:

```webidl
[NoInterfaceObject]
interface NonElementParentNode {
  // ...
};

// Implemented by: Document
// Implemented by: SomeOtherInterface [OTHERSPEC]
```

Reading the IDL from all other specs (or the set of specs you, as a spec author, care about having links to) during the spec build process probably isn't great.  Maybe @tabatkins can say how easy that would be.

---
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/dom/issues/249#issuecomment-218966371

Received on Friday, 13 May 2016 06:59:19 UTC