import { Docx } from "https://deno.land/x/docxml@2.4.2/mod.ts";
Represents the .docx file, which is essentially a ZIP archive with a bunch of XML files and some naming conventions.
An instance of this class can access other classes that represent the various XML files in a
DOCX archive, such as ContentTypes.xml
, word/document.xml
, and _rels/.rels
.
Properties
The utility function dealing with the XML for recording content types. Every DOCX file has exactly one of these.
Methods
Create a ZIP archive, which is the handler for .docx
files as a ZIP archive.
Static Methods
Instantiate this class by giving it a .docx
file if it is already loaded as a ZipArchive instance.
Instantiate this class by pointing at a .docx
file location.
Create a new DOCX with contents composed by this library's components. Needs a single JSX component
as root, for example <Document>
, <Section>
or <Paragragh>
.
Create an empty DOCX, and populate it with the minimum viable contents to appease MS Word.