Re: [WICG/webcomponents] [element-internals] How to get internals in base class and subclass, without leaking it to public (Issue #962)

You can always save it in a WeakMap and provide some API behind a closure to keep it hidden. It’s not particularly performant but it’s probably the best bet. 

Regardless, this is a perfect example of the need for `protected` class fields in JavaScript. 

-- 
Reply to this email directly or view it on GitHub:
https://github.com/WICG/webcomponents/issues/962#issuecomment-1198720124

You are receiving this because you are subscribed to this thread.

Message ID: <WICG/webcomponents/issues/962/1198720124@github.com>

Received on Thursday, 28 July 2022 23:24:58 UTC