google-developer-training / basic-android-kotlin-compose-training-mars-photos

Solution code for Android Basics in Kotlin course
https://developer.android.com/courses/android-basics-kotlin/course?gclid=CjwKCAjw4c-ZBhAEEiwAZ105RTyT-iaLHzrhMBUXdMhO230ZDwOwxxI2x4RgK8DwBxK8t1h0wmU_QxoCi4YQAvD_BwE
Apache License 2.0
72 stars 66 forks source link

Add Repository #38

Open DmitrySergienko opened 1 year ago

DmitrySergienko commented 1 year ago

URL of codelab:

https://developer.android.com/courses/pathways/android-basics-compose-unit-5-pathway-2#codelab-https://developer.android.com/codelabs/basic-android-kotlin-compose-add-repository

Specify the language of the codelab if it is not English:

Kotlin

In which task and step of the codelab can this issue be found?

Codelab: Load and display images from the internet Task: 2. Add repository and Manual Dependency Injection Step: 6 Add repository to ViewModel Sub_step: 8

Describe the problem

The description "Update the code to pass variable viewModel as an argument to the MarsPhotosApp composable."is not matching to the pice of code:

MarsPhotosTheme {
    val viewModel: MarsViewModel =
        viewModel(factory = MarsViewModel.Factory)
    MarsPhotosApp(viewModel)
}

Steps to reproduce?

  1. Go to the codelab and review missmatching:

Codelab: Load and display images from the internet Task: Add repository and Manual Dependency Injection Step: 6 (Add repository to ViewModel) Sub_step: 8

Versions _Android Studio version:_no matter _API version of the emulator:_no matter

Additional information Include screenshots if they would be useful in clarifying the problem.

Nickrader commented 1 year ago

Also, solution does not include this code in MainActivity.kt Solution Branch: coil-starter Also compared against branch main.

osuleymanova commented 1 year ago

Duplicate of #31, #29, #25, #20.