Skip to content

Latest commit

 

History

History
21 lines (17 loc) · 646 Bytes

use-font-awesome.md

File metadata and controls

21 lines (17 loc) · 646 Bytes

How to use font-awesome icons

Here are the packages that you need to install:

npm install --save @fortawesome/fontawesome-svg-core
npm install --save @fortawesome/free-solid-svg-icons
npm install --save @fortawesome/react-fontawesome

Here is a code example:

import ReactDOM from 'react-dom'
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'
import { faCoffee } from '@fortawesome/free-solid-svg-icons'

const element = <FontAwesomeIcon icon={faCoffee} />

References: