Whenever possible, you should be using string resources to make sure your app can easily be translated to other languages. However to read a string resource, you need access to the context which you don't have in ViewModels. In this video I show you how you can solve this problem.
Get limited 20% discount on all my courses using the code HAPPY-EASTER:
https://pl-coding.com/premium-courses...
💻 Let me personally review your code and provide individual feedback, so it won't backfire and cost you a fortune in future:
https://elopage.com/s/philipplackner/...
🎓 Become an industry-ready developer in the Mobile Dev Campus:
https://pl-coding.com/campus?utm_sour...
🎁 Get my FREE 4.5h course "The Best Practice Guide to Android Architecture":
https://pl-coding.com/best-practice-g...
Read our weekly Android blog:
https://pl-coding.com/blog
Join this channel to get access to perks:
/ @philipplackner
Get the initial source code for this video here:
https://github.com/philipplackner/Uni...
Get the final source code here:
https://github.com/philipplackner/Uni...
Join my Discord server:
/ discord
Regular programming advice on my Instagram page: / _philipplackner_
Checkout my GitHub: https://github.com/philipplackner
You like my free content? Here you can buy me a coffee:
https://www.buymeacoffee.com/philippl...
Nesta página do site você pode assistir ao vídeo on-line How to Use String Resources In a ViewModel - Android Studio Tutorial duração hora minuto segundo em boa qualidade , que foi baixado pelo usuário Philipp Lackner 13 Abril 2022, compartilhe o link com seus amigos e conhecidos, no youtube este vídeo já foi visto 44,823 vezes e gostou 1.5 mil espectadores. Boa visualização!