Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple favicon input sources #265

Closed
quittle opened this issue Mar 19, 2021 · 3 comments · Fixed by #331
Closed

Multiple favicon input sources #265

quittle opened this issue Mar 19, 2021 · 3 comments · Fixed by #331

Comments

@quittle
Copy link

quittle commented Mar 19, 2021

Is your feature request related to a problem? Please describe.
For a project, I have a busy logo at a high resolution but it looks terrible as a favicon. I have a stripped-down version that's a lot simpler and looks good when rendered at 16x16. Because this plugin generates icons at various sizes, it would be great if I could provide multiple source images and have the plugin choose the most appropriate image given the size.

Describe the solution you'd like
Provide an Array<string> or { int: string } with the different icon sizes so the plugin chooses the smallest image >= a targetted image size for each output.

Describe alternatives you've considered

  • Manually generating all the files
  • Give up - Only generating small icons with the simplified icon
  • Give up - Using a large version of the simplified icon and generating all sizes

Additional context
I believe this feature may be supported by the favicons library, but am unsure if that's true.

@jantimon
Copy link
Owner

jantimon commented May 2, 2021

I like the idea but it would be probably a lot of work to build it..

Do you want to do a POC as a pull request?

@quittle
Copy link
Author

quittle commented May 5, 2021

Hey, sorry. I don't have time to work on it. I'd love the feature but will move forward with the third alternative for now.

@andy128k
Copy link
Collaborator

This plugin relies on favicons package and that package actually allows to pass multiple sources. It picks a source image by its size. (there are some frictions in the current version 6.2.2 and it is recommended to sort source images by size in advance, upcoming 7.0.0 does not have such issue).

carlhopf pushed a commit to carlhopf/favicons-webpack-plugin that referenced this issue Oct 11, 2022
favicons >= 7.0.0 picks source image by it's size,
solves jantimon#265
carlhopf pushed a commit to carlhopf/favicons-webpack-plugin that referenced this issue Oct 11, 2022
favicons >= 7.0.0 picks source image by it's size,
solves jantimon#265
carlhopf added a commit to carlhopf/favicons-webpack-plugin that referenced this issue Oct 11, 2022
favicons >= 7.0.0 picks source image by it's size,
solves jantimon#265
carlhopf added a commit to carlhopf/favicons-webpack-plugin that referenced this issue Oct 12, 2022
favicons >= 7.0.0 picks source image by it's size,
solves jantimon#265
andy128k pushed a commit that referenced this issue Oct 12, 2022
favicons >= 7.0.0 picks source image by it's size,
solves #265
andy128k pushed a commit that referenced this issue Oct 12, 2022
favicons >= 7.0.0 picks source image by it's size,
solves #265
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants