docx
    Preparing search index...

    Class TableBorders

    Represents table borders in a WordprocessingML document.

    The tblBorders element specifies the borders for all cells in the table. Each side that isn't given is a thin single line, unless fillMissingSides is false, when it is left to the table's style.

    Reference: http://officeopenxml.com/WPtableBorders.php

    new TableBorders({
    top: { style: BorderStyle.SINGLE, size: 6, color: "000000" },
    bottom: { style: BorderStyle.SINGLE, size: 6, color: "000000" },
    });

    // To remove all borders
    new TableBorders(TableBorders.NONE);

    Hierarchy (View Summary)

    Index
    NONE: {
        bottom?: Omit<IBorderOptions, "color"> & { color?: string };
        insideHorizontal?: Omit<IBorderOptions, "color"> & { color?: string };
        insideVertical?: Omit<IBorderOptions, "color"> & { color?: string };
        left?: Omit<IBorderOptions, "color"> & { color?: string };
        right?: Omit<IBorderOptions, "color"> & { color?: string };
        top?: Omit<IBorderOptions, "color"> & { color?: string };
    } = ...

    No borders. Its borders are declared with hex colors, as they were before borders took colors of the document's theme, so that code reading them still compiles.

    • get writtenAs(): readonly BaseXmlComponent[] | undefined
      Internal

      The components written in this one's place, one after another, when it can't be written as a single element, such as a run with another run in its children. Undefined when it is written as itself.

      Returns readonly BaseXmlComponent[] | undefined