Skip to main content

Icon

An icon component which renders icon from vector library.

How to use

import React from 'react';
import {Icon} from '@gyri/native-ui-components';

const MyComponent = ({style, className}) => (
<Icon
style={style}
className={className}
source="camera"
color={MD3Colors.error50}
size={20}
/>
);

export default MyComponent;

Props

#NameData typeDefault valueValuesDescription
1styleobjectCustom style object
2classNamestring''It defined nativewind style classes.
3colorstringColor of the icon.
4allowFontScalingboolean
5sourceIcon to display.
6sizenumberSize of icon.

For more details https://callstack.github.io/react-native-paper/docs/components/Icon