PHPackages                             ahmadpriatama/fontawesome-markers - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. ahmadpriatama/fontawesome-markers

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

ahmadpriatama/fontawesome-markers
=================================

Iconic markers for Map, based on the Font-Awesome icons

012.4kPHP

Since Feb 11Pushed 10y agoCompare

[ Source](https://github.com/ahmadpriatama/fontawesome-markers)[ Packagist](https://packagist.org/packages/ahmadpriatama/fontawesome-markers)[ RSS](/packages/ahmadpriatama-fontawesome-markers/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependenciesVersions (1)Used By (0)

fontawesome-markers
===================

[](#fontawesome-markers)

An export of the fontawesome glyphs into named SVG Paths in javascript.

All glyphs have the same names as font-awesome, except they are capitalised, and underscored, eg "exclamation-circle" becomes "EXCLAMATION\_CIRCLE"

Usage
-----

[](#usage)

To use this library, you only need to include `fontawesome-markers.min.js`, and reference it like the examples below.

If you're a masochist, you can try extracting other webfonts (or newer versions of Font Awesome) using the scripts in `extractor/`

Example - Font Awesome on Google Maps
-------------------------------------

[](#example---font-awesome-on-google-maps)

You can use these paths, in products like Google Maps, for example:

```
new google.maps.Marker({
    map: map,
    icon: {
        path: fontawesome.markers.EXCLAMATION_CIRCLE,
        scale: 0.5,
        strokeWeight: 0.2,
        strokeColor: 'black',
        strokeOpacity: 1,
        fillColor: '#f8ae5f',
        fillOpacity: 0.7,
    },
    clickable: false,
    position: new google.maps.LatLng(lat, lng)
});
```

Example - Font Awesome on Canvas
--------------------------------

[](#example---font-awesome-on-canvas)

You can also draw them to canvas, using the new Path2D api, you may need to use a [polyfill for unsupported browsers](https://github.com/google/canvas-5-polyfill)

```
var canvas = document.getElementsByTagName('canvas')[0];
var ctx = canvas.getContext("2d");
var path = new Path2D(fontawesome.markers.EXCLAMATION_CIRCLE);
ctx.strokeStyle="#ff0000";
ctx.lineWidth=2;
ctx.fillStyle="#0000ff";
ctx.translate(0, 64);
ctx.fill(path);
ctx.stroke(path);
```

Example - Loading Font Awesome Markers via JSON/ XHR
----------------------------------------------------

[](#example---loading-font-awesome-markers-via-json-xhr)

Instead of including it as an inline script, you can also load it with JSON/XHR.

```
var fontawesome = {
   markers: null
};
var xhr = new XMLHttpRequest();
xhr.onload = function(){
  fontawesome.markers = JSON.parse(this.responseText);
}
xhr.open("get", "fontawesome-markers.json", true);
xhr.send();
```

Update
======

[](#update)

- 11th Februari 2016 - Updated to fontawesome 4.4.0
- 16th October 2014 - Updated to fontawesome 4.2.0
- 7th August 2014 - Updated to fontawesome 4.1.0, see the [Fontawesome Upgrade Guide](https://github.com/FortAwesome/Font-Awesome/wiki/Upgrading-from-3.2.1-to-4) for the list of changed names.
- 26th September 2013 - Changed font extraction process - Glyph size is a much more manageable 64px now, and rotation / flip corrected.

###  Health Score

24

—

LowBetter than 31% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity19

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 80% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/dd1738688f600a2d838e3f4e9f3866697e1df2a1767cef623ec68d23d99d4ca3?d=identicon)[ahmadpriatama](/maintainers/ahmadpriatama)

---

Top Contributors

[![nathan-muir](https://avatars.githubusercontent.com/u/3112329?v=4)](https://github.com/nathan-muir "nathan-muir (12 commits)")[![ahmadpriatama](https://avatars.githubusercontent.com/u/303305?v=4)](https://github.com/ahmadpriatama "ahmadpriatama (2 commits)")[![ShaneHarvey](https://avatars.githubusercontent.com/u/5015933?v=4)](https://github.com/ShaneHarvey "ShaneHarvey (1 commits)")

### Embed Badge

![Health badge](/badges/ahmadpriatama-fontawesome-markers/health.svg)

```
[![Health](https://phpackages.com/badges/ahmadpriatama-fontawesome-markers/health.svg)](https://phpackages.com/packages/ahmadpriatama-fontawesome-markers)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
