How To Import Font-awesome In Node.js To Use In React.js?
I am working with node.js and react.js. I already imported my own css file like so: import React from 'react'; import Modal from 'react-modal'; import './../App.css'; this works f
Solution 1:
Here's how i did it entirely in the front end react side:
Include font awesome inside the
<head>
tag<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
Install react-fontawesome
npm install --save react-fontawesome
Import the file and use it in your react components
importFontAwesomefrom'react-fontawesome'; // ..rest of your code<FontAwesomename="linkedin"size="2x"/>
Post a Comment for "How To Import Font-awesome In Node.js To Use In React.js?"