Skip to content

Android Compose Add a Scrollable List #241

@kcnd15

Description

@kcnd15

Name of the Codelab or Codelab URL
https://developer.android.com/codelabs/basic-android-kotlin-compose-training-add-scrollable-list?continue=https%3A%2F%2Fdeveloper.android.com%2Fcourses%2Fpathways%2Fandroid-basics-compose-unit-3-pathway-2%23codelab-https%3A%2F%2Fdeveloper.android.com%2Fcodelabs%2Fbasic-android-kotlin-compose-training-add-scrollable-list#2

Section 3. Add a list to your app

Describe the problem
Function "fun AffirmationList" is later called as "AffirmationsList", therefore it should be renamed to "AffirmationsList" (ie adding the missing "s").
Besides, the following snippet is wrong, because it does not reference the property "modifier" but the class "Modifier" in the assignment:
"@composable
fun AffirmationsApp() {
val layoutDirection = LocalLayoutDirection.current
Surface(
Modifier = Modifier
...
"

The corrected version is
"@composable
fun AffirmationsApp() {
val layoutDirection = LocalLayoutDirection.current
Surface(
modifier = Modifier
...
"

In which lesson and step of the codelab can this issue be found?
Lesson number + step number: Add a scrollable list, step 3

How to reproduce?
What are the exact steps to reproduce the problem?
Copying the source code shows errors in Android Studio.

Versions

  1. What version of Android Studio are you using? Android Studio Panda 2
  2. What API level are you targeting? API v36

Additional information
Add any other context about the problem here.

codelab: basic-android-compose-training-add-scrollable-list

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions