Skip to content

Element custom attribute's styles are only applied on initalization but not on further changes. #7914

Description

@mannok

Environment
Provide version numbers for the following components (information can be retrieved by running tns info in your project folder or by inspecting the package.json of the project):

  • CLI: 6.1.2
  • Cross-platform modules:
  • Android Runtime: Android 9
  • iOS Runtime:
  • Plugin(s):

Describe the bug
Element custom attribute's styles are only applied on initalization but not on further changes.

To Reproduce

  1. check bgRed value in console by clicking get bgRed // you will get false
  2. click toggle to invert bgRed from false to true
  3. check bgRed value in console again by clicking get bgRed // you will get true

Expected behavior
background color will change from blue to red after step 2

Sample project
https://play.nativescript.org/?template=play-vue&id=qXgtKz&v=2

Additional context
I can confirm this is not a bug of vue/angular framework as other developer from angular has also reported that this is not work in augular either. Link is provided as follow:

nativescript-vue/nativescript-vue#557 (comment)

Activity

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

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions