Skip to content

Instantly share code, notes, and snippets.

View icanerdogan's full-sized avatar
🏠
Working from home

İbrahim Can Erdoğan icanerdogan

🏠
Working from home
View GitHub Profile
@icanerdogan
icanerdogan / Activity
Created July 9, 2023 14:59
Kotlin Flow
class MainActivity : AppCompatActivity() {
private lateinit var binding: ActivityMainBinding
private val viewModel : MainViewModel by viewModels()
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
binding = ActivityMainBinding.inflate(layoutInflater)
setContentView(binding.root)
plugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
id 'kotlin-kapt'
id 'dagger.hilt.android.plugin'
id 'androidx.navigation.safeargs'
id 'kotlin-android-extensions'
}
android {