GT2/GT2-iOS/node_modules/react-native-vector-icons/lib/create-icon-set-from-fontel...

17 lines
391 B
JavaScript
Raw Normal View History

2018-02-12 17:26:06 +00:00
import createIconSet from './create-icon-set';
export default function createIconSetFromFontello(
config,
fontFamilyArg,
fontFile
) {
const glyphMap = {};
config.glyphs.forEach(glyph => {
glyphMap[glyph.css] = glyph.code;
});
const fontFamily = fontFamilyArg || config.name || 'fontello';
return createIconSet(glyphMap, fontFamily, fontFile || `${fontFamily}.ttf`);
}