Font Awesome Stylus
v4.7.1
منفذ القلم لخط رائع
استيراد خطوط الخط في مشروعك وتكوين مسار الخطوط بشكل صحيح (مسار FA-FANT $)
bower install font-awesome-stylus
npm install font-awesome-stylus
تعيين مسار الخط
$fa-font-path = "../fonts"
// OR
$fa-font-path = "http://netdna.bootstrapcdn.com/font-awesome/4.7.0/fonts"مثال على مطالبة واستخدام الوسيطة الوسيطة الخطية لإنشاء وظيفة ترجمة للاستفادة من الأطر الأخرى.
var fontAwesome = require ( 'font-awesome-stylus' ) ,
stylus = require ( 'stylus' ) ;
function compile ( str ) {
return stylus ( str )
. use ( fontAwesome ( ) ) ;
}لاستيراد خطوط الخط الكامل في ملف القلم الخاص بك:
@import "font-awesome-stylus"قم بتضمين أيقونة باستخدام Mixin
.my-icon
fa(user)
http://fortawesome.github.io/font-awesome