@breeffy/icons
TypeScript icon, indicating that this package has built-in type declarations

0.9.0 • Public • Published

@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.

Package Sidebar

Install

npm i @breeffy/icons

Weekly Downloads

0

Version

0.9.0

License

Apache-2.0

Unpacked Size

44.1 kB

Total Files

31

Last publish

Collaborators

  • victor.malov