[DEPRECATED] `Variable`

I’m going through Chapter three and when doing the examples for “Working with variables” I get the following console warning.

ℹ️ [DEPRECATED]Variableis planned for future deprecation. Please considerBehaviorRelay as a replacement. Read more at: https://git.io/vNqvx

Are there any plans to update this portion of the book? And in the meantime has anybody refactored the examples to use BehaviorRelay instead of Variable?

1 Like

So far the book has had yearly updates so most likely there will be a new version shortly after RxSwift 5 is out.

2 Likes

There are debates about Variable as BehaviorRelay is not a complete drop-in replacement. Some, like me, tend to favor keeping Variable around. We’ll see what happens next and will update the book accordingly.

1 Like

This topic was automatically closed after 166 days. New replies are no longer allowed.