encodeToByteString

open suspend fun encodeToByteString(format: F): ByteString(source)

Encodes this material into a ByteString in the specified format.

Use encodeToByteStringBlocking when calling from non-suspending code.