@eigenpal/docx-editor-core/docx/serializer
DOCX XML Serializers
Lower-level Document → OOXML transforms. For the round-trip "model in, .docx archive out" path, use ./docx instead.
Functions (11)
serializeBlockContentfunctionSource ↗
Serialize a single block content item (paragraph, table, or block SDT).
Exported so the footnote/endnote serializer can reuse the exact same block-level emission the document body uses — preserving tracked-change wrappers (w:ins/w:del), paragraph/run properties, fields, and tables inside note bodies instead of reimplementing a minimal serializer.
declare function serializeBlockContent(block: BlockContent): string;serializeCommentsfunctionSource ↗
Serialize comments array to comments.xml content (backwards-compatible wrapper)
declare function serializeComments(comments: Comment[]): string;serializeDocumentfunctionSource ↗
Serialize a complete Document to valid document.xml
declare function serializeDocument(doc: Document): string;serializeDocumentBodyfunctionSource ↗
Serialize a DocumentBody to document.xml body content
declare function serializeDocumentBody(body: DocumentBody): string;serializeEndnotesfunctionSource ↗
Serialize endnotes to word/endnotes.xml content.
declare function serializeEndnotes(endnotes: Endnote[]): string;serializeFootnotesfunctionSource ↗
Serialize footnotes to word/footnotes.xml content.
declare function serializeFootnotes(footnotes: Footnote[]): string;serializeHeaderFooterfunctionSource ↗
Serialize a HeaderFooter object to valid OOXML XML
declare function serializeHeaderFooter(hf: HeaderFooter): string;serializeParagraphfunctionSource ↗
Serialize a paragraph to OOXML XML (w:p)
declare function serializeParagraph(paragraph: Paragraph): string;serializeRunfunctionSource ↗
Serialize a run to OOXML XML (w:r)
declare function serializeRun(run: Run): string;serializeSectionPropertiesfunctionSource ↗
Serialize section properties (w:sectPr)
declare function serializeSectionProperties(props: SectionProperties | undefined): string;serializeTablefunctionSource ↗
Serialize a table to OOXML XML (w:tbl)
declare function serializeTable(table: Table): string;