Skip to content

mikerdean/tailwindcss-fa

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tailwind Font Awesome Plugin

This plugin for Tailwind adds Font Awesome font faces and classes to your CSS output dynamically.

Installation

npm install --save-dev https://github.com/mikerdean/tailwindcss-fa.git

Or if you use yarn then:

yarn add --dev https://github.com/mikerdean/tailwindcss-fa.git

You will require the Font Awesome fonts to be available in the file system for your project.

Configuration

Add to your tailwind.config.js:

const fontawesome = require('tailwindcss-fa');

module.exports = {
    theme: {
        // other configuration
    },
    plugins:[
        fontawesome({ version: '5.15.4' })
    ]
};

Options

The plugin takes a configuration object with the following keys with the default settings show below:

{
    brands: false, // enable brand icons
    duotone: false, // enable duotone icons (pro only)
    light: false, // enable light icons (pro only)
    path: null, // path for your font location
    pro: false, // enable pro icon output (free otherwise)
    regular: true, // enable regular icons
    solid: true, // enable solid icons
    thin: false, // enable thin icons (pro v6 only)
    version: '6.0.0-beta2' // font awesome version
}

This plugin supports Font Awesome version 5.0.1 and upwards and can support the free or pro varities.

About

Tailwind CSS plugin for fontawesome v5 and v6 (free and pro versions).

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors