Simplest way to add fontawesome to spfx webpart

Simplest way to add fontawesome to spfx webpart

2019/05/06 Office 365 Programming SharePoint 0

Do this on the top of you tsx file

import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
import * as fontawesome from '@fortawesome/free-solid-svg-icons';

Then put this in your render function

<FontAwesomeIcon icon={fontawesome.faSearch} size="1x" />


read count : 8

Leave a Reply

Your email address will not be published. Required fields are marked *