What's the difference between binding ($) and .self?

I'm confused. If I get an error, I just replace it with the other and it just works, but what I don't know is why it works. Both share the same value with the variable they're bonded to, so what's the difference?
Answered by Claude31 in 638977022
With $ you access a var that has been declared as @State.

With self you access a "basic" var
Accepted Answer
With $ you access a var that has been declared as @State.

With self you access a "basic" var

what's the difference?

Binding and .self are completely different things, so it is hard to answer to what's the difference.

What sort of usages do you have in mind? Can you show some example codes including ones you get some error and need replacing?

With $ you access a var that has been declared as @State.

With self you access a "basic" var

Haha. I can't believe I didn't notice that. Thanks a lot!
What's the difference between binding ($) and .self?
 
 
Q