Can’t seem to find a working example of this.
EDIT: Misunderstood your question, sorry.
Thanks for addressing anyhow.
I wonder if there may be a Principal.toBlob() method available for TS somewhere? It looks like that could be used to do the trick. I seem to recall maybe running across this method in one of the @dfinity packages, but can’t find it anymore…