Michał Diner

    Michał Diner

    1 year ago
    Why passing
    content: @Composable ColumnScope.() -> Unit
    in
    content: @Composable () -> Unit
    and invoking it in
    AnimatedVisibility(...) {
       content()
    }
    Cancels the ColumnScope?
    Doris Liu

    Doris Liu

    1 year ago
    That's because
    AnimatedVisibility
    is a
    Layout
    itself. Therefore when
    content
    gets put in the AnimatedVisibility, it's no longer a direct child of
    Column
    . Therefore ColumnScope extensions will have no effect on
    content
    .