I want to use font-awesome in my project, after install this package via npm I want to import it into main component index.js.
import 'font-awesome/css/font-awesome.min.css';
I have tried to import scss instead of css and still not working.
Later I'm trying to use in some other components:
<i className='fas fa-heart' />
And I'm getting rectangles instead of heart icons.
I have used: npm i font-awesome to install
In console I have no errors. How to fix this ?? With CDN is working but I don't want to use this in index.html, I want to install it and import.
className='fa fa-heart'instead ofclassName='fas fa-heart'. Nothing else comes in my mind as the css are applied as expected in my apps