@breeffy/icons
@breeffy/icons
npm i @breeffy/icons
@breeffy/icons

@breeffy/icons

Monorepo with UI components.

by breeffy

0.9.0 (see all)License:Apache-2.0TypeScript:Built-In
npm i @breeffy/icons
Readme

@breeffy/icons

Component to show FontAwesome icons.

Features

  • Duotone icons support
  • FontAwesome v6 support
  • TypeScript support
  • Compatible with styled-components
  • Compatible with styled-components css property

Peer Dependencies

"peerDependencies": {
  "react": "*",
  "react-native": "*",
  "react-native-svg": "*"
}

See this section about peer dependencies and how to get correct versions.

Installation

# Install react-native-svg peer dependency
$ yarn add react-native-svg
# Install @breeffy/icons package
$ yarn add @breeffy/icons
# Install FontAwesome icon packs
$ yarn add @fortawesome/free-solid-svg-icons

Configuration

Add required icons or styles into library

import { library } from '@fortawesome/fontawesome-svg-core';
import { fas } from '@fortawesome/free-solid-svg-icons';

library.add(fas);

Usage

import { Icon } from '@breeffy/icons';
import type { IconProps } from '@breeffy/icons';

export const Icon = () => {
  return <Icon icon={['far', 'address-book']} />;
};

See storybook for use case examples. Also see react-native-fontawesome documentation, most of it is still valid.

No alternatives found
No tutorials found
Add a tutorial
No dependencies found

Rate & Review

100
No reviews found
Be the first to rate