Simple FontAwesome 5 Vue.js 2 component


Keywords
fontawesome, font-awesome, vue, vue.js, component, icon
License
MIT
Install
npm install vue-fa@1.1.2

Documentation

vue-fa

npm npm npm npm

github travis codecov

Simple FontAwesome 5 Vue.js 2 component.

Documents and examples.

Installation

npm install vue-fa --save

Usage

<template>
  <div>
    <fa :icon="faFlag"/>
  </div>
</template>

<script>
  import Fa from 'vue-fa'
  import { faFlag } from '@fortawesome/fontawesome-free-solid'

  export default {
    components: {
      Fa
    },

    data() {
      return {
        faFlag
      }
    }
  }
</script>

Attributes

<fa
  :icon="faFlag"
  fw
  flip="horizontal"
  pull="left"
  :rotate="90"
  size="2x"/>
  • fw: fixed width
  • flip: string values horizontal, vertical, both
  • pull: string values left, right
  • rotate: number or string values 90, 180, 270, 30, -30 ...
  • size: string values xs, sm, lg or 2x, 3x, 4x ...