# MediumEditor Object API (v5.0.0) - [Initialization Functions](#initialization-functions) - [`MediumEditor(elements, options)`](#mediumeditorelements-options) - [`destroy()`](#destroy) - [`setup()`](#setup) - [`addElements()`](#addelementselements) - [`removeElements()`](#removeelementselements) - [Event Functions](#event-functions) - [`on(targets, event, listener, useCapture)`](#ontargets-event-listener-usecapture) - [`off(targets, event, listener, useCapture)`](#offtargets-event-listener-usecapture) - [`subscribe(name, listener)`](#subscribename-listener) - [`unsubscribe(name, listener)`](#unsubscribename-listener) - [`trigger(name, data, editable)`](#triggername-data-editable) - [Selection Functions](#selection-functions) - [`checkSelection()`](#checkselection) - [`exportSelection()`](#exportselection) - [`importSelection(selectionState, favorLaterSelectionAnchor)`](#importselectionselectionstate-favorlaterselectionanchor) - [`getFocusedElement()`](#getfocusedelement) - [`getSelectedParentElement(range)`](#getselectedparentelementrange) - [`restoreSelection()`](#restoreselection) - [`saveSelection()`](#saveselection) - [`selectAllContents()`](#selectallcontents) - [`selectElement(element)`](#selectelementelement) - [`stopSelectionUpdates()`](#stopselectionupdates) - [`startSelectionUpdates()`](#startselectionupdates) - [Editor Action Functions](#editor-action-functions) - [`cleanPaste(text)`](#cleanpastetext) - [`createLink(opts)`](#createlinkopts) - [`execAction(action, opts)`](#execactionaction-opts) - [`pasteHTML(html, options)`](#pastehtmlhtml-options) - [`queryCommandState(action)`](#querycommandstateaction) - [Helper Functions](#helper-functions) - [`checkContentChanged(editable)`](#checkContentChangededitable) - [`delay(fn)`](#delayfn) - [`getContent(index)`](#getcontentindex) - [`getExtensionByName(name)`](#getextensionbynamename) - [`resetContent(element)`](#resetcontentelement) - [`serialize()`](#serialize) - [`setContent(html, index)`](#setcontenthtml-index) - [Static Functions/Properties](#static-functionsproperties) - [`getEditorFromElement(element)`](#geteditorfromelementelement) - [`version`](#version) ## Initialization Functions ### `MediumEditor(elements, options)` Creating an instance of MediumEditor will: * Convert all passed in elements into `contenteditable` elements. * For any `