encodeToString
override fun <T> encodeToString(serializer: SerializationStrategy<T>, value: T): String
Content copied to clipboard
Serializes the value into an equivalent JSON using the given serializer.
Throws
if the given value cannot be serialized to JSON.