Ember Fontsource
Easily add fontsources to your Ember project in 2 easy steps.
Background
This Ember addon is adapted from [https://github.com/jeffjewiss/ember-typeface]
Installation
ember install ember-fontsource
Usage
- Install Ember Typeface:
ember install ember-fontsource
- Pick a fontsource from the list of over 800 available and add it to your project:
npm install fontsource-lato --save-dev
That’s it!
You are now free to use font-family: "Lato"
in your application’s styles.
Advanced Usage
Ember Typeface will try to look through your node_modules
to discover fontsource packages. If fontsources are specified in the config options in your app’s evironment: ENV.fontsourceOptions.fontsources
the two lists will be merged for unique values. However, you can choose to disable this auto discovery and configure which fontsources are imported into your project.
// config/environment.jsmodule { let ENV = ... fontsourceOptions: disableAuto: true // default is false, disable to manually choose fontsources fontsources: 'lato' ;};
Commands
ember fontsource:active
– view a list of the fontsources to be included in the appember fontsource:list
– view a list of all the available fontsourcesember fontsource:search <name>
– perform a fuzzy search on the list of fontsources