Can not find jsreport-proxy module
-
I want to merge my pages via script but can not find jsreport-proxy module in npm. Is this module deprecated or private? Any solutions? Thanks
-
jsreport-proxy
is a virtual module provided by jsreport.
Therequire('jsreport-proxy')
should always work inside the script and you shouldn't need to install anything special.
-
Thanks! I want to reproduce the playground https://playground.jsreport.net/w/anon/vaN5s7yU in my local followed by the steps
npm install jsreport-cli -g
mkdir jsreportapp
cd jsreportapp
jsreport init
jsreport configure
jsreport start
but I am still facing some issues. It shows my jsreport is not defined if I console.log it after import jsreport-proxy, I think afterRender is not call either. Is there a way to download and check the package.json and config file for this playground?
-
There is no extra config needed.
The steps you mentioned should prepare jsreport app that will properly handle the playground demo.
Try to export from playground, import it to your local and run it. It should produce the same result.
-
Thanks, I did not link the script to the template so it did not ran. Currently I will need to install jsreport package in order to make jsreport-proxy work, but jsreport is too big including chromium which I do not need. I just want to embed the script to my code, can I install a smaller version of jsreport?
-
Please elaborate more on how you plan to use jsreport.
-
I want to add watermark to my generated report, but I only have jsreport-client installed so the report is correctly rendered but can not merge. I will need pdf-util to merge my watermark page to the generated report pages, it should work like your previous answer https://forum.jsreport.net/topic/1360/add-copy-with-watermark-pdf-utils/2. But I am running the function on AWS lambda there is size limit for the code and node packages. So I will need a smaller package to make jsreport-proxy work as expected.
-
Have you seen our aws lambda tutorial?
https://jsreport.net/learn/aws-lambda-serverless
-
Hi @jan_blaha
I have tried to use jsreport-proxy, but I got the same error as @赵大程
For creating pdf I use node.js and jsreport-core with packages:
jsreport-pdf-utils, jsreport-handlebars, jsreport-chrome-pdf, jsreport-scripts
Do I need some additional packages for possibility to use module jsreport-proxy?
Thanks for help)