Kotlin Context Receivers Made Easy!
Vložit
- čas přidán 1. 07. 2024
- 💻 Join my new Refactoring Legacy Code course now: bit.ly/47dzTLT
📩 Sign up for my new newsletter here 👉 bit.ly/YCNewsletter102
✅ Join my Community on Discord:
/ discord
In this video, we will see how and when to use the awesome feature of Kotlin Context Receivers.
👨🏽🏭 Who I am:
I'm Younes Charfaoui, a Software Engineer and an Android Developer. I make videos about Android development, Technology, and productivity for software engineers.
😋 Be My Friend:
💻 GitHub - github.com/Younes-Charfaoui/
🐦 Twitter - / charfaouiyounes
📑 Medium - / mxcsyounes
📷 Instagram - / charfaoui.younes
🌍 My website - www.charfaouiyounes.com
This tip is very useful specially when you want to provide a context for your unit tests I think
Using android Context and the Kotlin Context is far too confusing
This video is a good topic but needs to be redone without using Android Context
A custom class would be better and appropriate example
Thanks for your feedback Chris, Will work on another example!.
without context receivers creating general extension functions would be a nightmare, generics doesn't help either