Mohd Hasan
Mohd Hasan

Reputation: 337

How to rotate 180 deg a fontawesome icon?

can any one tell me that how can i rotate a font awesome icon 180 degree. Actually i want to use a truck icon which is directed to right side but i found it left side rotated.

For ex:- <i class="fa fa-truck"></i>

Upvotes: 8

Views: 16832

Answers (4)

Cloud
Cloud

Reputation: 240

Just add the class 'fa-rotate-180'

Upvotes: 2

Zuber
Zuber

Reputation: 3473

Use transform css to achieve this:

.fa {
  transform: rotateZ(180deg);
}

Upvotes: 13

Roland
Roland

Reputation: 27719

You can use the transform css option combine it with rotate() function. See it in action

Upvotes: 0

Fabian
Fabian

Reputation: 660

This helped me:

.fa {
    -webkit-transform: rotate(180deg);
    -moz-transform: rotate(180deg);
    -ms-transform: rotate(180deg);
    -o-transform: rotate(180deg);
    transform: rotate(180deg);
}

Upvotes: 13

Related Questions