Android Jetpack Compose Example

Setting up interactive layouts in composable functions.

ComposeView.kt
import androidx.compose.runtime.*
import com.snapit.sdk.compose.TryOnWidget

@Composable
fun ProductDetailScreen() {
    TryOnWidget(
        apiKey = "smd_live_your_key",
        garmentUrl = "https://...",
        onSuccess = { resultUrl ->
            // render result in view
        }
    )
}