homepage icon indicating copy to clipboard operation
homepage copied to clipboard

Provide a npm library for the SVG icons

Open pierrebaronqumu opened this issue 2 years ago • 2 comments

Describe the bug Hi, first of all, thank you very much for your icon set, we are really impressed by it in my company.

We were wondering if there were any plans to release an npm library containing only the SVGs. We saw this folder for the icon font: https://github.com/phosphor-icons/phosphor-icons/tree/master/assets but it does not get exported by NPM.

I am happy to provide any help required.

Best regards

pierrebaronqumu avatar Apr 19 '22 10:04 pierrebaronqumu

Hey @pierrebaronqumu! We don't have any plans to provide an asset-only package, and they aren't included in our libraries for size concerns. Do you have a specific use-case in mind? Not sure how it would fit in the npm ecosystem to just use it for file storage.

As always, the latest assets can be downloaded at https://phosphoricons.com/assets/phosphor-icons.zip.

rektdeckard avatar Apr 29 '22 23:04 rektdeckard

We need to use the svgs and not the React/Vue/icon font projects as we have to deal with multiple frameworks in our apps. We could use the icon font but we had issues with those in the past and we prefer working directly with svgs.

We currently download the zip file as you mentioned but this does not come with any versioning system. Having an npm library would provide versioning which would make it easier for us to update the icons.

From what I have seen so far, other libraries like Bootstrap icons, Feather icons, ... provide the SVG files.

pierrebaronqumu avatar May 03 '22 16:05 pierrebaronqumu

Hey @pierrebaronqumu, we now have the @phosphor-icons/core package that exposes catalog information and raw SVG assets. I should caution that it's quite new and known bugs exist with SVG module resolution before Vite 4.1.0, but is tested and working with both Webpack and Vite 4.1.x.

rektdeckard avatar Feb 13 '23 19:02 rektdeckard

Awesome! Great work! This will be extremely helpful, thank you very much!

pierrebaronqumu avatar Feb 13 '23 20:02 pierrebaronqumu