[RUBY] [For those who create portfolios] How to use font-awesome-rails

What is font-awesome-rails?

Free use of web font icons Font Awesome library that can be easily used with rails Font Awesome is characterized by not blurring when enlarged. You can change it to your favorite color and size.

Introduced font-awesome-rails

Gemfile



gem 'font-awesome-rails'
$ bundle install

For application.css

*= require font-awesome

For application.scss

@import "font-awesome";

Ready

How to use

Basic

<i class="fa fa-Icon name"></i>

Resize

<i class="fas fa-Icon name fa-lg"></i>

fa-lg (1.333 ... times) fa-2x (double) fa-3x (3 times) fa-4x (4x) fa-5x (5 times)

If you want to change it to another size or color, you can write it in css.

reference

https://fontawesome.com/v4.7.0/icons/

Recommended Posts

[For those who create portfolios] How to use font-awesome-rails
[For those who create portfolios] How to use chart kick
[For those who create portfolios] How to use binding.pry with Docker
[For those who create portfolios] How to omit character strings
[For those who create portfolios] Search function created with ransack
How to use binding.pry for view files
How to create a Maven repository for 2020
[Ruby] How to use slice for beginners
[For those who create portfolios] Reduce mistakes and make the code easier to read -Rubocop Airbnb-
How to create a database for H2 Database anywhere
How to use an array for HashMap keys
[Rails] How to use Gem'rails-i18n' for Japanese support
How to use nginx-ingress-controller with Docker for Mac
[For super beginners] How to use autofocus: true
How to use Map
How to use with_option
How to use fields_for
How to use java.util.logging
How to use map
How to use collection_select
How to use Twitter4J
How to use active_hash! !!
How to use MapStruct
How to use TreeSet
[How to use label]
How to use hashes
How to create docker-compose
How to use JUnit 5
How to use Dozer.mapper
How to use Gradle
How to use org.immutables
How to use java.util.stream.Collector
How to use VisualVM
How to use Map
[Rails] How to create a signed URL for CloudFront
How to use an array for a TreeMap key
[Spring Boot] How to create a project (for beginners)
How to use Truth (assertion library for Java / Android)
How to use GitHub for super beginners (team development)
For those who want to use MySQL for the database in the environment construction of Rails6 ~.
How to create an application
How to use Chain API
[Java] How to use Map
How to use Priority Queuing
[Rails] How to use enum
How to use java Optional
How to use JUnit (beginner)
How to use Ruby return
[Rails] How to use enum
How to use @Builder (Lombok)
[Swift] How to use UserDefaults
How to use java class
How to use Swift UIScrollView
How to use Big Decimal
How to use String [] args
[Java] How to use string.format
How to use rails join
How to use Java Map
Ruby: How to use cookies
How to use dependent :: destroy
How to use Eclipse Debug_Shell