Skip to content

Commit f44a8e1

Browse files
committed
refactor: update type definition for tab icons
1 parent 2ae13be commit f44a8e1

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

example/src/app/(tabs)/_layout.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
import FontAwesome from '@expo/vector-icons/FontAwesome';
22
import { Tabs } from 'expo-router';
33
import { useCallback } from 'react';
4+
import type { ColorValue } from 'react-native';
45

56
export default function TabLayout() {
67
const renderBarIcon = useCallback(
78
(name: keyof typeof FontAwesome.glyphMap) => {
8-
return ({ color }: { color: string }) => (
9+
return ({ color }: { color: ColorValue }) => (
910
<FontAwesome size={28} name={name} color={color} />
1011
);
1112
},

0 commit comments

Comments
 (0)