Convert binary array to base64
-
Hello, I want know what library is using Jsreport for load images from disc. Buffer?? Thanks
-
hi, (i'm going to assume that the question is about images used by assets)
the exact mechanism depends on the type of
@encodingthat you specify when calling an asset. for@encoding=dataURIor@encoding=base64it is just buffer serialization (buffer.toString('base64')) the only difference is that@encoding=dataURIadds a bit more data to make possible inline an image in thesrcattribute of an img tag.you can check how all of this is done in the assets repository
-
Thanks!!!!!