Article

Creating an Article: Main Steps

Plan the design for your article and create it in Apple News Format.

Overview

When you create an article in Apple News Format, you start by creating a JSON document file. The file contains code that specifies the layout for your article, provides the content, and customizes the look. The file is processed and rendered as an article in Apple News. The following figure shows the basic tasks associated with creating an article.

Main Steps

  1. Create an article.json document file. All article document files must have the name article.json. Start by adding the ArticleDocument object and its required properties, or download this sample file. You can use any text editor to edit the code in your article.json file. See Choose a Text Editor. Create a unique folder to hold the article.json file and any other files you’ll be publishing with this article, such as image files.

  2. Plan the layout of your article. Decide how many layout columns your design will need. See Planning the Layout for Your Article.

  3. Add components that contain your article’s content. The content of your article—the text, photos, and other information—is contained in an array of components in your article.json file. Each component has a specific function—for example, a title, a caption, body text, or a video. For an overview of the different kinds of components you can have in your article, see Components; to learn how to add components, see Adding Components.

  4. Position the components in your article. Use the ComponentLayout object to specify where each component will appear horizontally in your article document. See Positioning the Content in Your Article.

  5. Customize the appearance of your article. Include styles, animations, behaviors, and other effects. See Enhancing Your Articles with Styles and About Component Animations.

  6. Add the metadata for your article. See Metadata.

Once your article is finished, you can publish it to Apple News. See Create an Article.

See Also

Essentials

JSON Concepts and Article Structure

Understand basic JSON concepts and become familiar with the structure of an Apple News Format article.

object ArticleDocument

The root object of an Apple News article, containing required properties, metadata, content, layout, and styles.