survey-pdf
Version:
A UI component that uses SurveyJS form JSON schemas to render forms as PDF documents. It populates PDF fields with data collected using SurveyJS Form Library and lets you export your SurveyJS forms as editable or pre-filled PDFs.
28 lines (24 loc) • 913 B
JavaScript
/*!
* surveyjs - SurveyJS PDF library v2.5.21
* Copyright (c) 2015-2026 Devsoft Baltic OÜ - http://surveyjs.io/
* License: MIT (http://www.opensource.org/licenses/mit-license.php)
*/
import { P as PDFFormFillerBase, _ as __awaiter } from './pdf-form-filler-shared.mjs';
export { a as PDFJSAdapter, b as PDFLibAdapter } from './pdf-form-filler-shared.mjs';
import { writeFile } from 'fs';
class PDFFormFiller extends PDFFormFillerBase {
saveToFile(pdfBytes, fileName) {
return __awaiter(this, void 0, void 0, function* () {
return new Promise((resolve, reject) => {
writeFile(fileName, pdfBytes, (err) => {
if (err)
reject(err);
else
resolve();
});
});
});
}
}
export { PDFFormFiller };
//# sourceMappingURL=pdf-form-filler.node.mjs.map