slackhq/compose-lints

ComposeContentEmitterReturningValues incorrectly reports on compose functions with multiple top-level emitters

acrab opened this issue · 1 comments

Example code:

@Composable
fun Test(modifier: Modifier = Modifier){
    Text(text = "TextOne")
    Text(text = "TextTwo")
}

Expected result: ComposeMultipleContentEmitters lint rule will trigger

Actual result: Both that rule and ComposeContentEmitterReturningValues trigger, leading to a confusing set of warnings!

image

PR welcome!