Add new demo and remove tslint disable
This commit is contained in:
15
demo/demo25.js
Normal file
15
demo/demo25.js
Normal file
@ -0,0 +1,15 @@
|
||||
const fs = require("fs");
|
||||
const docx = require("../build");
|
||||
|
||||
var doc = new docx.Document();
|
||||
|
||||
var paragraph = new docx.Paragraph("Hello World");
|
||||
var institutionText = new docx.TextRun("Foo").bold();
|
||||
var dateText = new docx.TextRun("Bar").tab().bold();
|
||||
paragraph.addRun(institutionText);
|
||||
paragraph.addRun(dateText);
|
||||
|
||||
doc.addParagraph(paragraph);
|
||||
|
||||
var exporter = new docx.LocalPacker(doc);
|
||||
exporter.packPdf("My Document");
|
Reference in New Issue
Block a user