Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/docxml/mod.ts

TypeScript (component) library for building and parsing a DOCX file
Latest
import * as docxml from "https://deno.land/x/docxml@5.15.3/mod.ts";

Classes

The end of a range associated with a comment.

The start of a range associated with a comment.

A component that represents a line break, page break or section break in a DOCX document. Place this in one of the <Text>, <TextAddition> or <TextDeletion> components.

A component that represents a table cell.

The start of a range associated with a comment.

The end of a range associated with a comment.

The start of a range associated with a comment.

Represents the DOCX file as a whole, and collates other responsibilities together. Provides access to DOCX content types (ContentTypesXml), relationships (RelationshipsXml), the document itself (DocumentXml).

A component that represents a (simple) instruction field.

The end of a range associated with a complex field.

An instruction in a complex field.

The separator between the instruction of a compex field, and the last computed value.

The start of a range associated with a complex field.

A component that represents a hyperlink to another part of the same document.

A component that represents an image in your DOCX document. You can create a new image by passing any promise to an Uint8Array into the data prop, eg. get it from your file system or from a web request.

A component that represents a non-breaking hyphen. Place this in the <Text> component.

A component that represents a paragraph in your DOCX document, which is one of the most widely used components and the most likely to contain a style rule or other.

A component that represents a table row.

A component that represents a change-tracked table row that was inserted. Works the same way as a normal row, but requires some props describing the change.

A component that represents a change-tracked table row that was deleted. Works the same way as a normal row, but requires some props describing the change.

A component that represents a DOCX section, which could have its own page sizing options and so on.

A component that represents a special character from a different font.

A component that represents a tab space in a DOCX document. Place this in one of the <Text>, <TextAddition> or <TextDeletion> components.

A component that represents a table.

A component that represents text. All inline formatting options, such as bold/italic/underline, are in fact different props or styles on the <Text> component.

A component that represents a change-tracked text that was inserted.

A component that represents a change-tracked text that was deleted.

Functions

Converts centimeters to any of the other units of length.

Converts English metric units to any of the other units of length.

Converts half-points to any of the other units of length.

Converts inches to any of the other units of length.

The JSX pragma with which you can write <Paragraph> instead of new Paragraph({}).

Converts 8th-points to any of the other units of length.

Converts points to any of the other units of length.

Converts twentieth-points to any of the other units of length.

Type Aliases

A type describing the components accepted as children of BookmarkRangeEnd.

A type describing the props accepted by BookmarkRangeEnd.

A type describing the components accepted as children of BookmarkRangeStart.

A type describing the props accepted by BookmarkRangeStart.

A type describing the components accepted as children of Break.

A type describing the props accepted by Break.

A type describing the components accepted as children of Cell.

A type describing the props accepted by Cell.

A type describing the components accepted as children of Comment.

A type describing the props accepted by Comment.

A type describing the components accepted as children of CommentRangeEnd.

A type describing the props accepted by CommentRangeEnd.

A type describing the components accepted as children of CommentRangeStart.

A type describing the props accepted by CommentRangeStart.

A type describing the components accepted as children of Field.

A type describing the props accepted by Field.

A type describing the components accepted as children of FieldRangeEnd.

A type describing the props accepted by FieldRangeEnd.

A type describing the components accepted as children of FieldRangeInstruction.

A type describing the props accepted by FieldRangeInstruction.

A type describing the components accepted as children of FieldRangeSeparator.

A type describing the props accepted by FieldRangeSeparator.

A type describing the components accepted as children of FieldRangeStart.

A type describing the props accepted by FieldRangeStart.

A type describing the components accepted as children of Hyperlink.

A type describing the props accepted by Hyperlink.

A type describing the components accepted as children of Image.

A type describing the props accepted by Image.

An object that describes a size or length in various cross-computable units. Useful for telling the library how centimeters you would like one thing to be, while the one thing is defined as twentieth- points, EMU's or ostriches behind the scenes.

A type describing the components accepted as children of NonBreakingHyphen.

A type describing the props accepted by NonBreakingHyphen.

A type describing the components accepted as children of Paragraph.

A type describing the props accepted by Paragraph.

A type describing the components accepted as children of RowAddition.

A type describing the props accepted by RowAddition.

A type describing the components accepted as children of Row.

A type describing the components accepted as children of RowDeletion.

A type describing the props accepted by RowDeletion.

A type describing the props accepted by Row.

A type describing the components accepted as children of Section.

A type describing the props accepted by Section.

A type describing the components accepted as children of Symbol.

A type describing the props accepted by Symbol.

A type describing the components accepted as children of Tab.

A type describing the components accepted as children of Table.

A type describing the props accepted by Table.

A type describing the props accepted by Tab.

A type describing the components accepted as children of TextAddition.

A type describing the props accepted by TextAddition.

A type describing the components accepted as children of Text.

A type describing the components accepted as children of TextDeletion.

A type describing the props accepted by TextDeletion.

A type describing the props accepted by Text.

A type describing the components accepted as children of WatermarkText.

A type describing the props accepted by WatermarkText.