Mandatory Sections

This commit is contained in:
Dolan Miu
2019-07-31 08:48:02 +01:00
parent bf80311ef7
commit ac5b15d0e3
63 changed files with 1194 additions and 1588 deletions

View File

@ -16,26 +16,24 @@ describe("Packer", () => {
revision: "1",
lastModifiedBy: "Dolan Miu",
});
const paragraph = new Paragraph("test text");
const heading = new Paragraph({
text: "Hello world",
heading: HeadingLevel.HEADING_1,
});
file.add(
new Paragraph({
text: "title",
heading: HeadingLevel.TITLE,
}),
);
file.add(heading);
file.add(
new Paragraph({
text: "heading 2",
heading: HeadingLevel.HEADING_2,
}),
);
file.add(paragraph);
file.addSection({
children: [
new Paragraph({
text: "title",
heading: HeadingLevel.TITLE,
}),
new Paragraph({
text: "Hello world",
heading: HeadingLevel.HEADING_1,
}),
new Paragraph({
text: "heading 2",
heading: HeadingLevel.HEADING_2,
}),
new Paragraph("test text"),
],
});
packer = new Packer();
});