Adding Components

Learn the basics for adding components to your article.


An article can have many types of components, including text, images, social media posts, data tables, and so on. Each component is associated to both a ComponentLayout object that determines its placement in an article and a ComponentStyle object that determines its appearance.

If you like to treat a set of components as a group, add them to a Container component. See Nesting Components in an Article. Otherwise, place individual components directly into the component's array in ArticleDocument.

The following sample shows three components (a title component, an author component, and an intro component) in a components array.

"components": [
      "role": "title",
      "layout": "titleLayout",
      "text": "New Title",
      "textStyle": "titleStyle"
      "role": "author",
      "layout": "authorLayout",
      "text": "Angie Anders | Anders & Meyerson | March 20, 2018",
      "textStyle": "authorStyle"
       "role": "intro",
       "text": "The beginning was not nearly close enough and the ending had yet to be written."

See Also

First Steps

object Component

Properties shared by all component types.