kamilagraf / react-swm-icon-pack

MIT License
35 stars 6 forks source link

Not very convenient to use #5

Open iksent opened 1 year ago

iksent commented 1 year ago

Hey! I tried your library but it doesn't seem to be developer-friendly now.

There are 3 global issues for me:

  1. No TypeScript

  2. Not ready for Next because of missing transpilation. So it requires additional configs like https://github.com/martpie/next-transpile-modules (next@13 supports it by default) and this is not the best approach.

  3. Icons colors are hardcoded in code You should set "currentColor" for all strokes/paths/elements and not a specific color - so developers can just set "color: red" style for SVG element and icon will change color without any troubles.

image

Please take a look at react-feather library - it works smoothly without additional settings, as it should be.

Anyway, thanks for your library, this is a really good starting point for using SWM icons!

iksent commented 1 year ago

I've managed to fix #3 with such config:

<SWMIconProvider color="currentColor" set="curved">
...
</SWMIconProvider>

Shouldn't it be currentColor by default?