Skip to content

Exposing reference to the Widget through an optional variable#33

Open
sirphoenix wants to merge 7 commits intozouhir:masterfrom
sirphoenix:master
Open

Exposing reference to the Widget through an optional variable#33
sirphoenix wants to merge 7 commits intozouhir:masterfrom
sirphoenix:master

Conversation

@sirphoenix
Copy link
Copy Markdown

Adds a new "component" parameter to the render() function which can be either a string or object.

When passing a string like 'foo' the reference will be set to window[foo].
When passing an object it will set its property 'ref' to the widgets reference.

Also made some code cleanup since there were no eslint-settings to be found.

@viperfx
Copy link
Copy Markdown

viperfx commented Sep 30, 2020

@sirphoenix can these changes be used to make a widget that can show/hide based on a click's on the host element?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants