Skip to content

Commit

Permalink
Add table demo
Browse files Browse the repository at this point in the history
  • Loading branch information
dolanmiu committed Jul 29, 2017
1 parent ee81f3c commit 411c0da
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions demo/demo4.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
const docx = require('../build');

var doc = new docx.Document();

const table = doc.createTable(4, 4);
table.getCell(2, 2).addContent(new docx.Paragraph('Hello'));


var exporter = new docx.LocalPacker(doc);
exporter.pack('My Document');

console.log('Document created succesfully at project root!');

1 comment on commit 411c0da

@maugenst
Copy link

@maugenst maugenst commented on 411c0da Nov 10, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry ... my fault... table is implicitly added to doc.

Please sign in to comment.