Would you like to clone this notebook?

When you clone a notebook you are able to make changes without affecting the original notebook.

Cancel

DOCX Demo 7

node v8.17.0
version: 1.0.0
endpointsharetweet
// docx landscape demo const docx = require('docx'); var express = require("@runkit/runkit/express-endpoint/1.0.0"); var app = express(exports); app.get("/", (req, res) => { var doc = new docx.Document(undefined, { orientation: "landscape", }); var paragraph = new docx.Paragraph("Hello World"); doc.addParagraph(paragraph); const expressPacker = new docx.ExpressPacker(doc, res); expressPacker.pack("Document"); });
Loading…

no comments

    sign in to comment