Replies: 1 comment
-
|
drop the usage of a variable and expose the widget itself const fn1 = ({props}) => {
const content = Widget.Stack({...props, children: {}})
const box = Widget.Box({child: content})
return Object.assign(box, {content})
}
const newWidget = fn1({prop: {transition: "crossfade"}})
newWidget.content.transition = "none"or you can access children widgets directly const fn2 = ({props}) => {
const content = Widget.Stack({...props, children: {}})
return Widget.Box({child: content})
}
const newWidget = fn2({prop: {transition: "crossfade"}})
newWidget.children[0].transition = "none" |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Let's say I've a setup like this,
How can I bind to
_propertiesand spreadvaluesin theStackwidget? I'm trying to create a custom widgetnewWidgetand I want to controlStackwidget's property usingnewWidgetlater in my script (i.e.newWidget._properties.value = {transition: "slide_right"}).Beta Was this translation helpful? Give feedback.
All reactions