Its a good point. If you really did want to put binary data in JSON format for sending over a Web API, you would most likely base64 encode it. This is already perfectly possibly with the existing APIs.
Perhaps what is needed is simply to allow Bytes
to be passed over ports, but not to bother with encoders/decoders that turn them into Value
s representing javascript objects. The Bytes
would have to be top-level arguments to the port functions and not embedded deeper as a field of some object.