Hi everyone I am checking my compose UI with ktlin...
# ktlint
p
Hi everyone I am checking my compose UI with ktlint but I am having this issue `...\app\src\main\java\com\...\app\ui\theme\Theme.kt3329`: Not a valid Kotlin file (type expected) (cannot be auto-corrected) Line points to
() -> Unit
in nested function Theme.kt:
Copy code
@Composable
fun MusicApp_theme(
    darkTheme: Boolean = isSystemInDarkTheme(),
    content: @Composable () -> Unit
) {
    val colors = if (darkTheme) {
        DarkColorPalette
    } else {
        LightColorPalette
    }

    MaterialTheme(
        colors = colors,
        typography = Typography,
        shapes = Shapes,
        content = content
    )
}
e
what version of ktlint? this causes no errors in the current release
p
Copy code
com.github.shyiko:ktlint:0.31.0
e
that's over 3 years old, upgrade
❤️ 1
p
I found issue is more about that I added @Composable inside typealias Alright I will
Thanks for info)
118 Views