S
S
symnoob2020-06-16 16:08:45
Sass
symnoob, 2020-06-16 16:08:45

How can I make this code more readable?

Hello everyone,

I would like to transform this code into a more readable form, is it possible?

<th>
  <div style="position: relative"> # <i class="fas fa-sorting-down" style="position:absolute; right:0"></i></div>
</th>


and I would like this abra-kadabra to look like this:

<th>
  <div class='sorting-asc'> # </div>
</th>


or even worse, like this:

<th class='sorting-asc'>
  #
</th>

Answer the question

In order to leave comments, you need to log in

1 answer(s)
F
FinGanapre, 2020-06-16
@symnoob

If with examples, then you need to do so
. How to come to this?
Open the source of the icon font (for example , version 4 )
We see that all classes with icons simply set :before with content: '/icon code from the site'
And the main class sets the font family.
We combine both in your class - we get the result.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question