Active-CSS / active-css

The epic event-driven browser language for UI with functionality in one-liner CSS. Over 100 incredible CSS commands for DOM manipulation, ajax, reactive variables, single-page application routing, and lots more. Could CSS be the JavaScript framework of the future?
https://activecss.org
Other
42 stars 7 forks source link

2.4.0 host clarification #82

Closed bob2517 closed 3 years ago

bob2517 commented 3 years ago

This issue takes precendence over any other issues regarding hosts.

Hosts are now clarified as the parent element surrounding either a shadow DOM container or a strictlyPrivateVars component.

Referencing host attributes will only work in these two scenarios. The reason being that all other components have access to inherited variables from upper scopes, and so they never practically need to pass around attributes for variable use.

The host element reference will refer to the same host.

The parent element reference can access component parents, so the main host reference is not necessary. It has more use for attribute passing and so the emphasis is now on that.

Note to self: Internally, _splitIframeEls needs sorting out so that this is clear, and probably _getSel. In renderCompDomsDo, set the host of the component as a component reference variable for quick reference in thos places.

bob2517 commented 3 years ago

This works in certain scenarios but more testing is needed. The latest code is now on the 2.4.0 branch.