@express-document-sdk

Namespace: Constants

The Constants namespace groups together the enumerations used by the Document APIs. It is the canonical way to access these values from user code — every enum below can be reached through Constants.X, regardless of whether it is also available as a top-level named export.

Available at the top level

These enumerations are re-exported at the top level of @express-document-sdk, so they can be imported directly as named exports or accessed through Constants.X. Both forms refer to the same enum — pick whichever reads best at the call site.

import { BlendMode, Constants, editor } from "express-document-sdk";

const [node] = editor.context.selection;

node.blendMode = BlendMode.multiply;

node.blendMode = Constants.BlendMode.multiply;
Enumeration
Description
ArrowHeadType
Experimental
BlendMode
Experimental
EditorEvent
This enum represents the supported editor events.
FillRule
Experimental
FillType
Experimental
ResizeBehavior
An enum for controlling the behavior of Node.resize.
SceneNodeType
Experimental
StrokePosition
Experimental
StrokeType
Experimental
TextAlignment
Experimental
TextLayout
Experimental
TextScriptStyle
Represents a text script style.
VisualEffectType
Visual effects that can be applied to a text node.

Only available via Constants

These enumerations are only reachable through the Constants namespace — they are not re-exported at the top level, so import { ParagraphListType } from "express-document-sdk" would not resolve.

import { Constants, editor } from "express-document-sdk";

const [node] = editor.context.selection;

await node.createRendition({ format: Constants.CreateRenditionFormat.png });

const listStyle = {
    type: Constants.ParagraphListType.ordered,
    numbering: Constants.OrderedListNumbering.doubleZeroPrefixNumeric
};
Enumeration
Description
CreateRenditionFormat
Experimental
OrderedListNumbering
Numbering types used to display ordered lists: 1, A, a, I, i 01, 001.
ParagraphListType
Indicates list type: see UnorderedListStyleInput and OrderedListStyleInput.
TextStyleSource
Experimental