npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

pub-pkg-font-awesome

v3.0.5

Published

Use Font Awesome v4.7.0 glyphs from pub-server markdown

Downloads

65

Readme

pub-pkg-font-awesome

https://jldec.github.io/pub-pkg-font-awesome

Enables Font Awesome v4.7.0 glyphs from any pub-server markdown.

Installation

  1. install pub-pkg-font-awesome with npm install --save pub-pkg-font-awesome
  2. add pub-pkg-font-awesome to your pub-config pkgs

CSS

This package will inject <link rel="stylesheet" href="/css/font-awesome.css"> into your main template.

Alternatively, if you set inject:false on the theme, you can use one of the other mechanisms described here.

Note: Unlike the regular font-awesome.css, this package does not include a class for every icon. The Markdown renderer will insert the correct icon unicode character into the generated HTML without help from CSS.

Usage from Markdown

This package includes a customized marked renderer.

_!{icon-name}_ in your markdown, will render <span class="fa">{icon-glyph-code}</span>

E.g. in link text:

[Link to facebook _!facebook_](your-facebook-url)

Link to facebook !facebook

Or in a heading:

### _!warning_ Warning

!warning Warning

For a complete list of all the icon names see https://jldec.github.io/pub-pkg-font-awesome

Controlling icon size and other features

You can add css classnames (without the fa- prefix) after the icon name, separated with space. E.g.

_!spinner 3x spin_

!spinner 3x spin

Supported classnames include: lg, 2x, 3x, 4x, 5x, spin, pulse, border, rotate-90, rotate-180, rotate-270, flip-horizontal, and flip-vertical

pull-left and pull-right are not supported from markdown, but can be used from a template)

For examples of icons with the css classnames see https://fontawesome.com/v4.7.0/examples/

Usage from handlebars

For additional control of the rendered HTML, this package includes the following Handlebars Helpers

  • {{{faGlyph name}}} produces the glyph unicode for insertion into HTML e.g. {{{faGlyph yen}}} generates &#xf157.

  • {{{faIcon name extra}}} produces the same HTML as the markdown _!name extra_.

  • {{#eachFa}}{{/eachFa}} Block helper for enumerating all the glyphs. The iterator produces {name: glyph:} for each icon.

E.g. The HTML for the Condensed icon-list page was generated using the following:

{{#eachFa~}}
<div class="blox">{{{faIcon name}}}</div>
{{/eachFa}}

Font Awesome v4.7.0 License

Font License

  • Applies to all desktop and webfont files in the fonts directory:
  • License: SIL OFL 1.1
  • URL: https://scripts.sil.org/OFL

Code License

  • Applies to CSS and LESS files in the following directories: font-awesome/css/, font-awesome/less/, and font-awesome/scss/. License: MIT License URL: https://opensource.org/licenses/MIT-license.html

Documentation License

  • Applies to all Font Awesome project files that are not a part of the Font or Code licenses.
  • License: CC BY 3.0
  • URL: https://creativecommons.org/licenses/by/3.0/

Brand Icons

  • All brand icons are trademarks of their respective owners.
  • The use of these trademarks does not indicate endorsement of the trademark holder by Font Awesome, nor vice versa.
  • Brand icons should only be used to represent the company or product to which they refer.
  • Please do not use brand logos for any purpose except to represent that particular brand or service.

Plugin code

(c) Jürgen Leschner -- github.com/jldec -- MIT License