-
Notifications
You must be signed in to change notification settings - Fork 131
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
[Feature]: Produce more favicons for different devices #3440
Comments
Rsbuild also provides html.appIcon for generating apple-touch-icon and web app manifest icons. According to https://evilmartians.com/chronicles/how-to-favicon-in-2021-six-files-that-fit-most-needs, the icons currently provided by Rsbuild should fit most modern needs. favicons-webpack-plugin provides too many icons, I think Rsbuild will not support all of them, we can select the necessary icons to support. |
Thanks. That's a great post. Ok, agreed, we do not need too many favicons, but …
"... the icons currently provided by Rsbuild ..." iconS ⇽- that's in plural, yet when I do a basic run in production mode, it generates one favicon only: export default {
html: {
favicon: './src/assets/icon.png',
},
};
Since it produces one favicon only, I wonder if it is a bug and whether I should configure them manually with the |
Yes, you should configure the |
Well, in that case, I'd have to manually generate each app favicon for each size. |
Agreed, fair enough. Keep it lightweight. I wonder if the existing FaviconsWebpackPlugin would be compatible to reuse inside rsbuild? |
We cannot use See: But I think it is possible to make |
What problem does this feature solve?
It's me again. There is a neat webpack plugin which produces many different favicons, designed for all the different devices and phones. For example:
Link: https://github.com/jantimon/favicons-webpack-plugin
Upon build, it generates many different images and ultimately links them all in the final index HTML page. It works very well on iPhones and bookmarks among all different OS.
What does the proposed API look like?
Presently, you provide one favicon configuration:
https://rsbuild.dev/config/html/favicon
It would be good to expand it further and have it produce various favicons for some common OS's and mobile phones by default. And have the theme colour configurable based on your design. Just an idea.
The text was updated successfully, but these errors were encountered: