Package Exports
- dorpheus-card-generator
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (dorpheus-card-generator) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
dorpheus-card-generator
Creates a html and pdf file from the tickets in the current active sprint.
Usage as a library
index.js exports a single method called jiraToPdf() which takes a properties object, and responds with a html-pdf CreateResult.
The CreateResult can be converted to a buffer with toBuffer, or to a file with toFile.
For example;
function getJiraPdfAsBuffer(props: IProperties) {
return jiraToPdf(props)
.then((createResult) => {
return new Promise<Buffer>((resolve, reject) =>
createResult.toBuffer((err, buffer) =>
buffer && resolve(buffer) || reject(err);));
});
}
Running as Standalone
To run as a standalone application;
$ npm i
$ npm run build
$ npm run start
# Do something with out.pdf/out.html
The standalone application depends on the following properties being defined in your ~/.gradle/gradle.properties
$ cat ~/.gradle/gradle.properties
jiraUrl=https://org.atlassian.net
jiraUsername=user@org.com
jiraPassword=hunter12
jiraBoardId=123