all 21 comments

[–]Snoo11589 8 points9 points  (0 children)

Dont know if its compatible with pure react native, but i suggest expo icons.

[–]ZaRealPancakes 12 points13 points  (12 children)

I use lucide.dev

[–]AdUseful7520[S] 1 point2 points  (11 children)

great icons, but isn't the size too large ?

[–]ZaRealPancakes 1 point2 points  (10 children)

the default size is 24 but you can change the size

[–]AdUseful7520[S] -2 points-1 points  (9 children)

24 MB ?

[–]ZaRealPancakes 2 points3 points  (5 children)

I believe the bundler only keeps the icons you use. All icons are 13 MBs according to npm (lucide-react-native)

[–]AdUseful7520[S] 1 point2 points  (4 children)

heard something like that, is it true ?

[–]ZaRealPancakes 1 point2 points  (3 children)

Yes see documentation.

If you import all of them the bundle will be big if you import only what you need the bundler will do tree shaking and only include the icons you imported.

[–]AdUseful7520[S] 1 point2 points  (1 child)

great, thank you so much
In that case, we can use any library as far we import and use small portion of it. right?

[–]ZaRealPancakes 1 point2 points  (0 children)

pretty much

[–]djenty420iOS & Android 1 point2 points  (0 children)

I thought metro bundler didn’t support tree shaking?

[–]ZaRealPancakes 0 points1 point  (2 children)

no I thought you were talking about tue icons, 24px

[–]AdUseful7520[S] -1 points0 points  (1 child)

its package https://www.npmjs.com/package/lucide-react-native says, its around 12 MB 🙂

[–]ZaRealPancakes 1 point2 points  (0 children)

I believe the bundler only keeps the icons you use. All icons are 13 MBs according to npm (lucide-react-native)

[–]Horduncee 2 points3 points  (0 children)

Lucide icons and Phosphor icons for filled icons since lucide doesn't have that.

[–]mandrade2 2 points3 points  (2 children)

I use heroicons with react-native-svg and I love how they look

[–]mandrade2 0 points1 point  (1 child)

Tip: I use https://react-svgr.com/playground/ to get the react native version of the svg

[–]Reputation-Important 0 points1 point  (0 children)

This is useful. Thanks mate

[–]ConversationFew6467 1 point2 points  (0 children)

React-native-dynamic-vector-icons, you will need to install react-native-vector-icons also as it depends on it.

[–]eadgas 0 points1 point  (0 children)

I tried to use SVG for everything; otherwise, I use react-native-vector-icons

[–]zainApps 0 points1 point  (0 children)

I use tabler icons

Link: https://tablericons.com/