dot-style: Style pronoun

.styleR Documentation

Style pronoun

Description

The .style pronoun allows you to define styles for a tag element within the context of the element. Prior to the introduction of the .style pronoun tag styles were always applied outside or after constructing a tag element.

card() %>% background("primary") %>% display("flex")

However, once the content of a tag element grows to more than a few lines, associating the element's styles with the element becomes increasingly unintuitive. In these situations, make use of the .style pronoun.

card(
  .style %>%
    border("primary") %>%
    font("primary")
)

Usage

.style

nteetor/yonder documentation built on June 8, 2022, 1:36 p.m.