Client-side JavaScript PDF generation for Embereños.
npm install ember-js-pdf

Generate, render, and save PDF files in the browser with jsPDF. See examples of jsPDF.
* ember install ember-js-pdf
Render a PDF from an Array of steps:
``hbs`
{{js-pdf steps filename="tomster-facts"}}
Where:
`js`
export default Controller.extend({
steps: [
{setFontSize: 40},
{text: [35, 25, 'Tomsters loves jsPDF']}
]
});
Steps are arrays of PDF rendering commands with an array of arguments. All PDF rendering commands are listed here, with additional documentation of their arguments here.
Saving PDFs:
`hbs`
{{#js-pdf steps as |pdf|}}
{{/js-pdf}}
Rendering from a URL:
`hbs`
{{js-pdf src="https://bitcoin.org/bitcoin.pdf"}}
Toggling PDF visibility:
`hbs`
{{#js-pdf showPdf=false as |pdf|}}
{{pdf.filename}} is visible
{{!-- PDF Not visible --}}
{{/js-pdf}}
| Property | Type | Default | Available |
| ----------- | ------- | ------- | ------------------------- |
| orientation | String | p | portrait, landscape, p, l |
| unit | String | mm | pt, mm, cm, in |
| format | String | a4 | a0, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, b0, b1, b2, b3, b4, b5, b6, b7, b8, b9, b10, c0, c1, c2, c3, c4, c5, c6, c7, c8, c9, c10, dl, letter, government-letter, legal, junior-legal, ledger, tabloid, credit-card |
| compressPdf | Boolean | false | true, false |
* git clone this repositorycd ember-js-pdf
* yarn
*
* ember serve
* Visit your app at http://localhost:4200.
* npm test (Runs ember try:each to test your addon against multiple Ember versions)ember test
* ember test --server
*
* ember build`
For more information on using ember-cli, visit https://ember-cli.com/.