Create PDF & display PDF & Save To Server #1302
Unanswered
ErnestAbbott
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am able to create a PDF for the user to view etc. What I also want to do at the same time is to save the viewed PDF to a back-end server (AWS), without any under intervention.
I looked at blob, but didn't seem to make much progress with it. To see what blob does I performed a very simple test:
(note that MyDocument is in angular brackets, which this editor removes along with its content)
function MyTest2(){
const blobx= pdf( MyDocument ).toBlob();
console.log("blob");console.log(blobx);
return(<></>);
}
The output from blobx wasn't informative. I could see no properties etc that I could use,
A short example would be benefician
=== output ===
Promise { : "pending" }
: "fulfilled"
: Blob { size: 1549575, type: "application/pdf" }
size: 1549575
type: "application/pdf"
: BlobPrototype { slice: slice(), stream: stream(), text: text(), … }
arrayBuffer: function arrayBuffer()
constructor: function ()
size:
slice: function slice()
stream: function stream()
text: function text()
type:
Symbol(Symbol.toStringTag): "Blob"
<get size()>: function size()
<get type()>: function type()
: Object { … }
==== end output expanded ===
Beta Was this translation helpful? Give feedback.
All reactions