Issue importing custom icons

#1

is there a bug creating custom icons with expo version 25.0.0? When trying to :

import { createIconSetFromFontello } from ‘@expo/vector-icons’;

I get the error: _expo.Font.style is not a function. (In ‘_expo.Font.style(expoFontName)’, ‘_expo.Font.style’ is undefined.

in the node modules createIconSetFromFontello.js

import { Font } from ‘expo’;
import createIconSetFromFontello from ‘./vendor/react-native-vector-icons/lib/create-icon-set-from-fontello’;

export default function(config, expoFontName, expoAssetId) {
return createIconSetFromFontello(config, Font.style(expoFontName).fontFamily, expoAssetId);
}

Any suggestions?

#2

hi! this is fixed in sdk26, you can update with the instructions in https://blog.expo.io/expo-sdk-v26-0-0-is-now-available-2be6d9805b31

alternatively, you can install the newest version of ‘@expo/vector-icons’ temporarily (be sure to remove the manual installation when you update to sdk26) to resolve the issue. the latest version is 6.3.1

1 Like
#3

For anyone else running into this, update with

yarn upgrade expo

closed #4

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.