Hi everyone, I'm working on Summon (<https://githu...
# feed
y
Hi everyone, I'm working on Summon (https://github.com/yebaital/summon), a Kotlin Multiplatform UI library inspired by Compose but for web. It has components, modifiers, routing, SSR, and state management. I'm building a real project with it to create a working example so no guarantees yet! Would love any feedback from experienced Kotlin devs! Still early days, so API might change.
🔥 5
c
Hey! I see your README contains
Copy code
kotlin {
    sourceSets {
        val commonMain by getting {
            dependencies {
                implementation("code.yousef:summon:0.1.5")
            }
        }
        
        val jvmMain by getting {
            dependencies {
                implementation("code.yousef:summon-jvm:0.1.5")
            }
        }
        
        val jsMain by getting {
            dependencies {
                implementation("code.yousef:summon-js:0.1.5")
            }
        }
    }
}
but nowadays you can just write
Copy code
kotlin {
    sourceSets.commonMain.dependencies {
        implementation("code.yousef:summon:0.1.5")
    }
}
you don't need to re-declare your dependency for all platforms if it's already in the common code
Can I write a
if
in a
render
function?
y
@CLOVIS good point about gradle! Also I'm in the process of migrating to use
@Composable
functions instead of implementing an interface, and you can use if statements inside render functions of composables