GithubHelp home page GithubHelp logo

miguelcobain / broccoli-fontcustom Goto Github PK

View Code? Open in Web Editor NEW

This project forked from kinvey/broccoli-fontcustom

0.0 2.0 0.0 131 KB

Generate custom icon webfonts using Font Custom and Broccoli

License: MIT License

broccoli-fontcustom's Introduction

Broccoli Font Custom

Generate custom svg based webfonts using Font Custom and Broccoli

Installation

Install Font Custom on your system

On a Mac:

$ brew install fontforge ttfautohint
$ gem install fontcustom

On Linux:

$ sudo apt-get install fontforge ttfautohint
$ wget http://people.mozilla.com/~jkew/woff/woff-code-latest.zip
$ unzip woff-code-latest.zip -d sfnt2woff && cd sfnt2woff && make && sudo mv sfnt2woff /usr/local/bin/
$ gem install fontcustom

Add broccoli-fontcustom to your project

npm install --save-dev broccoli-fontcustom

Usage

Add broccoloi-fontcustom to your Brocfile.js

var fontCustom = require('broccoli-fontcustom');

Configure broccoli-fontcustom with the second configuration being any command line arguments to fontcustom (minus the -- before them) if there is no parameter to the argument specify null

// 'test/icons' is relative to your current working directory
var fontIcons = broccoli.makeTree('test/icons');
fontIcons = fontCustom(fontIcons, {
  // Output is relative to the resulting broccoli file.
  output: 'fonts',
  // Name the font file
  'font-name': 'Icons',
  // Disable the md5 hash being added to the end of the filenames
  'no-hash': null
  // Whatever templates you would like to use, by default it will generate `preview` and `css` templates
  templates: ['css','preview']
  // The prefix for each glyph's CSS class. Default: icon-
  'css-prefix': 'icon'
  // Display debug information
  debug: null
});

License

MIT - 2014 Kinvey, Inc.

broccoli-fontcustom's People

Contributors

myztiq avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.