[Nativescript][Android] Add badge on tabview tabs

android

#21

Thanks.
How did you get to that you need to __controller ? :slight_smile:


#22

It’s open source friend, you can check the code any time.


#23

I’m trying to debug the code using console.log, breakpoints…
but sometimes it so many information so I don’t which is the right thing to use…

Thanks anyway.


#24

How would you do to update the value of the badge? For example in angular im trying to bind a property to bageValue like so: [bageValue]=“count”. it works the first time i load the tabview but when i try updating the count property the value on the badge wont update. I also tried reusing the code in the addBadge method every time i update the value but that doesnt work either. My guess is that i would somehow have to remove the badge view first and then call addBadge again? If so how would i go about that


#25

Use property apis to keep listening for changes and update your UI.

https://docs.nativescript.org/core-concepts/properties

My earlier example was simple and assumes the badge is set on load.