getData.tsfile, which you can find by navigating to
src/template/inside the newly created package.
getDatafunction to the following to retrieve the first user from the database:
template.handlebarsfile which is also located inside the
custom.scssfile which is located in the
mainview, and update the view’s XML and TypeScript to the following:
yarn installin the root folder of your PDF report package:
hello_world_report git:(master) yarn install. This installs, among other things, the JourneyApps PDF CLI tool which you will use in the following steps.
yarn pdf initto initialize the PDF CLI functionality for this package, and follow the next prompts to connect to your app’s database.
yarn pdf watchto display the compiled PDF in your browser. Any changes made to the PDF will refresh the browser window. You can now proceed to make updates to your PDF and review the result instantly.
downloadPDFmethod on the HTML client after you have generated the PDF:
compilePDFmethod on the HTML client, in combination with the
compiledDataevent to the view TypeScript:
compilePDFmethod in the same way as the
downloadPDFmethod described above: