ComponentProps

Read access to a component's evaluated props with lenient, JavaScript-like conversions.

Functions

Link copied to clipboard
fun bool(key: String): Boolean?

The value as a boolean (booleans and "true"/"false" strings).

Link copied to clipboard
fun number(key: String): Double?

The value as a number (numbers and numeric strings).

Link copied to clipboard

Numbers (non-numbers coerced; invalid values become NaN, like Number()).

Link copied to clipboard
fun string(key: String): String?

The value if it is a string.

Link copied to clipboard

Strings (non-strings converted with String(value)).

Link copied to clipboard
fun text(key: String): String?

The value as display text (String(value)), or null when null or absent.