2 years ago

#32216

test-img

AbdulAzeez Olanrewaju

IonIcon Component to use Icons coming from "react-icons" package

I want to make IonIcon use react-icons like below.

enter image description here

Type 'IconType' is not assignable to type 'string'.

I understand the error, but is there a way i could still use react-icons.

Like this

enter image description here

Because i'm looping through some object, i'm picking some icons from ion-icons and react-icons, but react-icons has a type of IconType while ion-icons has a type of string | undefined. How do i merge these two icon libraries to use.

reactjs

ionic-react

ionic6

0 Answers

Your Answer

Accepted video resources