microsoft / fluentui-system-icons

Fluent System Icons are a collection of familiar, friendly and modern icons from Microsoft.
https://aka.ms/fluentui-system-icons
MIT License
5.64k stars 497 forks source link

Breaking change in @fluentui/react-icons v2.0.244 #727

Closed TehPers closed 2 weeks ago

TehPers commented 2 weeks ago

Version 2.0.244 of @fluentui/react-icons includes a breaking change to the exported bundleIcons function (caused by #726).

Not sure if this package tries to follow semver, but if so, the new LightIcon parameter should be marked as optional. We have some code at my workplace that started showing errors as a result of this package's version getting bumped in our lockfile. The docs also don't seem to be updated with info on how to use the new parameter, so I'm not sure how to fix it in our code either since it doesn't seem as though light versions of the icons are being exported, as far as I can tell at least. I'm planning to revert the version back to 2.0.243 in our package.json to fix this issue, but wanted to raise it here as well for awareness.

The related line in that PR is packages/react-icons/src/utils/bundleIcon.tsx:12.

sven-pohl commented 2 weeks ago

Just adding the corresponding LightIcon is not possible for all Icons. Many icons are not available in in all sizes or even unsized. Therefore, I don't find a light equivalent for e.g. Person24Regular and some other. I need to revert to 2.0.243.