Skip to content

Font Awesome vector icons as Elm HTML components

Notifications You must be signed in to change notification settings

jystic/elm-font-awesome

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Font Awesome for Elm

Use the incredible Font Awesome vector icon library without leaving the comfort of your Elm environment.

This library exposes scalable vector icons as Elm HTML components.

Check out the Font Awesome website linked above to see what the icons look like.

How to use?

Check the complete example here.

Every Font Awesome icons automatically inherits CSS size and colors from their parents.

import FontAwesome.Regular as RegularIcon
import FontAwesome.Brands as BrandsIcon
import FontAwesome.Solid as SolidIcon


view _ =
    div
        [ style [ ( "width", "100px" ) ] ]
        [ div [ style [ ( "color", "red" ) ] ] [ RegularIcon.address_book ]
        , br [] []
        , div [ style [ ( "width", "300px" ) ] ] [ SolidIcon.address_book ]
        , br [] []
        , div [ style [ ( "color", "blue" ) ] ] [ BrandsIcon.fa_500px ]
        ]

About

Font Awesome vector icons as Elm HTML components

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Elm 99.7%
  • Shell 0.3%