- From: yuzhehan <notifications@github.com>
- Date: Tue, 27 Oct 2020 14:51:18 -0700
- To: w3c/webcomponents <webcomponents@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <w3c/webcomponents/issues/902@github.com>
In our virtual F2F breakout discussion for [DOM Parts API](https://github.com/rniwa/webcomponents/blob/add-dom-parts-proposal/proposals/DOM-Parts.md), naming for the new APIs, `Part`, could cause confusion with [CSS Shadow Parts](https://www.w3.org/TR/css-shadow-parts-1/).
**Current Proposal: DOM Parts**
```webidl
interface Part {...};
interface NodePart : Part {...};
interface AttributePart : NodePart {...};
interface ChildNodePart : NodePart {...};
interface PropertyPart : NodePart {...};
interface CustomPart : NodePart{...};
interface PartGroup {...};
```
**Naming alternatives to the `Parts API` :**
1. `Location` can be an alternative to `Part` since they point to locations in the DOM where mutation can happen.
The API becomes:
```webidl
interface Location {...};
interface NodeLocation : Location {...};
interface AttributeLocation : NodeLocation {...};
...
```
2. Another common term used to indicate a placeholder for future data is `binding`.
Frameworks like Angular and Vue uses `binding` to mark a place in an element where application data is inserted.
```webidl
interface Binding {...};
interface NodeBinding : Binding {...};
interface AttributeBinding : NodeBinding {...};
...
```
What do you guys think?
@EisenbergEffect @caridy @JanMiksovsky @rniwa @hober @justinfagnani @mfreed7
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/webcomponents/issues/902
Received on Tuesday, 27 October 2020 21:51:30 UTC