View Source Fontawesome (Fontawesome Icons v0.0.5)

Example usage:

<Fontawesome.icon icon="arrow-left" />

<Fontawesome.icon icon="icon2" style="solid" />

<Fontawesome.icon icon="another-icon" weight="sharp" />

<Fontawesome.icon icon="everything" style="thin" weight="sharp" size="2x" class="my-css-class" css="border: 1px solid red;" />

Has a single configuration option allowing you to register the free version only is used. When set this will (try to) override all non-free styling to be free only.

config :fontawesome,
  free_only: true

Additionally contains a list of icons.

Summary

Functions

Returns a list of all the brand icons

Style can be regular, solid, light, thin or duotone Weight defaults to nothing (classic) but can be set to sharp

Returns a list of all non-brand icons

The version of FontAwesome this was built against (for the icon lists)

Functions

@spec brand_icons() :: [String.t()]

Returns a list of all the brand icons

@spec icon(map()) :: Phoenix.LiveView.Rendered.t()

Style can be regular, solid, light, thin or duotone Weight defaults to nothing (classic) but can be set to sharp

Attributes

  • icon (:string) (required)
  • style (:string) - Defaults to "regular".
  • weight (:string) - Defaults to nil.
  • size (:string) - Defaults to nil.
  • class (:string) - Defaults to nil.
  • css (:string) - Defaults to nil.
@spec standard_icons() :: [String.t()]

Returns a list of all non-brand icons

@spec version() :: String.t()

The version of FontAwesome this was built against (for the icon lists)