1.0.0 • Published 2 years ago

@404-software/react-fontawesome v1.0.0

Weekly downloads
-
License
-
Repository
-
Last release
2 years ago

🎨 React Font Awesome 6 Icons

import { WormSolid } from '@404-software/react-fontawesome'

export const Icon = () => <WormSolid />

Credits

This package is a fork of react-native-iconic by Fernando Rojo.

Overview

  • 😎 Free, beautiful icons
  • 🔥 Customizable with SVGProps props
  • 🌲 Tree-shaken components
  • 🤖 TypeScript support
  • 📈 JS-only

Installation

yarn add @404-software/react-fontawesome

Usage

Each icon is exported as its own component with an adjusted name.

For example, to use the angle-down solid variant icon, import AngleDownSolid:

import { AngleDownSolid } from '@404-software/react-fontawesome'

You can also import * as FontAwesome:

import * as FontAwesome from '@404-software/react-fontawesome'

export const Icon = () => <FontAwesome.AngleDownSolid />

For a full directory of components, see the FontAwesome website.

Custom color

<AngleDownSolid color="black" />

Custom size

<AngleDownSolid height={30} width={30} />

How it works

The components are generated by svgr. I downloaded all the free icons from fontawesome.com and ran a script to codegen the files from there.

1.0.0

2 years ago