Olúwáṣeun Ṣóbándé
11/13/2025, 6:06 PMField.Text, Field.Boolean)
• ✅ Works seamlessly with Compose Multiplatform UI
• ✅ Built for Android + iOS (and ready for desktop/web later)
• Supports common validators like:
• RequiredValidator
• EmailValidator
• MinLengthValidator
• Custom validators
Quick example
val PasswordField = Field.Text("password")
Form(onSubmit = { println(PasswordField.value) }) {
FormField(
field = PasswordField,
default = "",
validators = listOf(
RequiredValidator("Password required"),
MinLengthValidator("At least 8 characters", 8))
) {
OutlinedTextField(
value = PasswordField.value,
isError = !PasswordField.isValid,
label = { Text("Password") },
supportingText = PasswordField.error?.let { { Text(it, color = MaterialTheme.colorScheme.error) } },
onValueChange = { PasswordField.value = it }
)
}
Button(onClick = ::submit) { Text("Sign Up") }
}
Looking for feedback
Since this is the first public release, I’d love to hear your thoughts:
• Does the API feel Kotlin-y enough?
• Anything confusing or repetitive about validation setup?
• Any missing validators or form patterns you’d expect?
• Would you use it in your Compose Multiplatform projects?
If you’ve tried it, even brief feedback or suggestions (naming, ergonomics, new ideas) would be hugely appreciated ❤️
Here's a demo video of the sample app in action.Kirill Grouchnikov
11/13/2025, 6:40 PMField.Password variant to match the expected interactive visuals of typing a password?Olúwáṣeun Ṣóbándé
11/13/2025, 8:17 PMField class is just for input types (String, Long, Boolean, etc), not visuals related.
Redacting a password input is up to the developer via the normal PasswordVisualTransformation on a compose TextField.
OutlinedTextField(
value = PasswordField.value,
isError = !PasswordField.isValid,
label = { Text("Password") },
supportingText = PasswordField.error?.let { { Text(it, color = MaterialTheme.colorScheme.error) } },
onValueChange = { PasswordField.value = it },
visualTransformation = PasswordVisualTransformation()
)Kirill Grouchnikov
11/13/2025, 8:37 PM