article: Specify the components of an article

Description Usage Arguments Examples

View source: R/block_articles.R

Description

The article() function is used exclusively within block_articles(), and having one, two, or three calls will arrange the articles in a row (or as a column of articles at lower screen widths).

Usage

1
article(image = NULL, title = NULL, content = NULL, link = NULL)

Arguments

image

An optional URL pointing to an image resource.

title

An optional title for the article.

content

An optional paragraph of text for the article.

link

An optional link to apply to the content elements.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
# We can define an article with a link
# to an image, title text, some content,
# and a link to relevant content
article <-
  article(
    image = "https://i.imgur.com/dxSXzGb.jpg",
    title = "Hong Kong",
    content =
      "Once home to fishermen and farmers, \\
      modern Hong Kong is a teeming, \\
      commercially-vibrant metropolis where \\
      Chinese and Western influences fuse.",
    link = "http://www.discoverhongkong.com"
  )

if (interactive()) article

rich-iannone/blastula documentation built on Oct. 17, 2020, 8:59 p.m.