This package contains a React Component, which implements the latest version of the official Ionicons into React.
To add the package to your existing React project just type in one of the following commands:
npm i @reacticons/ionicons
or
yarn add @reacticons/ionicons
importReactfrom'react';importIonIconfrom'@reacticons/ionicons';exportconstComponent=()=>(<><IonIconname="bag-outline"/></>);You can specify the icon size by using the optional size prop.
<IonIconname="bag-outline"size="small"/><IonIconname="bag-outline"size="large"/>This package supports all Ionicons of the matching version. To see a full list of them, you can take a look at the official Ionicons website.
By the way, the <IonIcon> Component has the same attributes as a typical <span> element.