Returns an instance of a popup component that displays an article next to a target DOM node.


var target = document.getElementById('popup-component-target');
var popup = window._elev.popupComponent(target, { articleId: '81565' });
// popup._destroy();


window._elev.popupComponent(target, options);

target (required)

The DOM node that the popup will appear next to.

options (required)

  • options.articleId (required)
    The ID of the article that should be displayed.


A popup component instance has the following methods:


Inserts the component into the DOM as a new element and attempts to position itself at the top right of the target. Equivalent to “opening” the popup.


Undoes insert logic and destroys component. Instance cannot be used after this is called. Equivalent to “closing” the popup; to “open” it again, create a new popup and insert it.

If you use this API or have suggestions for it’s improvement please get in touch about your experience.