Skip to main content
PptxEditor from @reductoai/pptx/editor is the editor without a UI. You send commands; it edits the deck, keeps undo history and returns a laid-out view. It has no DOM, so it runs in Node, in a worker or in a page. The editor UI runs on it.
Frames and click points are in hundredths of a millimetre (HMM_PER_PT per point), the unit of the layout IR.

The view

apply returns an EditorView; editor.view holds the last one.

Commands

Every edit is a PptxCommand, a plain object with a type. The main groups: isViewCommand(command) tells a view-only command (selection, navigation) from an edit.

Read the deck

PptxEditor.open(bytes, { onProgress }) reports parse and layout progress. To share the editor with other writers, see Collaboration.