- From: BronislavKlucka <notifications@github.com>
- Date: Thu, 12 May 2016 11:42:48 -0700
- To: w3c/webcomponents <webcomponents@noreply.github.com>
- Cc:
- Message-ID: <w3c/webcomponents/issues/499/218848650@github.com>
Matthaw, I do not want this to become our own discussion, but I'll try to respond one more time, hoping to make this point, ultimately it's up to others to decide 1/again, we have never been able to do what we wanted on the page, internals of user-agent own elements have always been hidden from us, no difference here. 2/ having object being just a container for methods and properties has always been a bad idea, most OOP languages have at least privates to hide internal states (it makes no difference whether it is field or DOM) and for decades we've tried to do this in ES. Aren't you annoyed every time you have to consider whether to attach everything on object and use constructor as a closed box around internals (but risking huge memory usage) or put things on prototype, but then leaking everything to outside word? I do not know your experience, and it's not entirely correct argument, but my experience of 25 years with sealed languages and 20 years with mishmashed web pages left me with deep feelings, that this concept of 'everything sees everything' is deeply flawed (I miss scoped styles...). This is simply conceptually wrong. I wander... have you protested on WeakMaps or Symbols at TC39? Those allow to create privates for plain ES... Where is any difference? 3/ Yes! It is more important, that the component's working on authors' page, than that developer wants to do whatever they want to do (and by hooking attachShadow or even altering source code they still may). It's his/hers component :). This simply creates a contract, contract between a author and all developers using this component (not just the one who want to screw it), it creates contact among different components on the page, what they can or cannot do to each other. This is, how it should have been from the beginning and we should be here discussing whether we need open mode... not the other way around. "Open" is, what's weird about ShadowDOM, not "closed". But I can accept both, because I will assume, that by using open component, I can touch inners, author is most likely sure, it will not cause any problem. But when I will see closed one, I will assume, that it is simply danger. 4/ And again, if you ever find yourself relying on the internal DOM of Shadow, either it's poorly written or you are using wrong component. This is simply both theoretically and practically correct way. B. --- 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/499#issuecomment-218848650
Received on Thursday, 12 May 2016 18:43:22 UTC