size

val JsonElement.size: Int

Returns the number of entries in a JsonObject or elements in a JsonArray. Extension property on JsonElement.

Throws

if this element is a primitive or JSON null