Stack

Applies a vertical margin between the child elements.

Read more Read less

Maturity: Stable

Usage

<.stack>
  <div>some block</div>
  <div>some other block</div>
</.stack>

By default, the margin is only applied to the direct children of the component. To apply a vertical margin on children at any nesting level, set the recursive attribute.

<.stack recursive>
  <div>
    <div>some nested block</div>
    <div>another nested block</div>
  </div>
  <div>some other block</div>
</.stack>

Training

Training a dog requires patience and consistency. Using positive reinforcement, like treats and praise, helps in teaching commands effectively.

Different breeds have unique traits. For example, Labradors are known for their friendliness, while Border Collies are celebrated for their intelligence.

Attribute Type Documentation Default Value
class :any

Any additional classes to be added.

Read more Read less
[]

Variations of the component should be expressed via modifier attributes, and it is preferable to use styles on the parent container to arrange components on the page, but if you have to, you can use this attribute to pass additional utility classes to the component.

The value can be a string or a list of strings.

recursive :boolean

If true, the stack margins will be applied to nested children as well.

false
rest :global

Any additional HTML attributes.

Required inner_block * :slot
<section>
  <h3>Training</h3>
  <p>
    Training a dog requires patience and consistency. Using positive
    reinforcement, like treats and praise, helps in teaching commands
    effectively.
  </p>
</section>
<p>
  Different breeds have unique traits. For example, Labradors are known
  for their friendliness, while Border Collies are celebrated for their
  intelligence.
</p>