Skip to content

Component attributes are not updated when they depend on parent state #148

@togglebyte

Description

@togglebyte

What happened
Passing state to children via attributes don't seem to work
for components.

The value does not update when the state does.
However using the attribute for a widget does in fact update.
Most likely the attribute is not subscribed to when used
for components.

What did you expect to happen
The component attribute to update.

Steps to reproduce
Steps to reproduce the behaviour:

@component [doesnotupdate: state.value]
// component.rs
context.attributes.get_as::<u32>("doesnotupdate"); // this does not update

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions