0

How can I make a text justified in Jekyll Now in the simplest way? I have tried {: .text-justify}, but isn't working.

David Jacquel
  • 51,670
  • 6
  • 121
  • 147
plaidshirt
  • 5,189
  • 19
  • 91
  • 181

1 Answers1

1

Well you're half the way.

You're using an Inline Attribute Lists (IAL) in order to add attributes to an html element.

Aenean massa. Cum sociis natoque penatibus ...
{: .my-class}

This will add a .my-class class to the paragraph.

<p class="my-class">Aenean massa. Cum sociis natoque penatibus …</p>

Now, you just have to add a corresponding cascading style sheet rule for this class.

.my-class{
   text-align: justify;
}

Important note: one accessibility best practice is to avoid justified text.

David Jacquel
  • 51,670
  • 6
  • 121
  • 147