-
-
Notifications
You must be signed in to change notification settings - Fork 9
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
usage of images key for array of images #8
Comments
since preset is global (will be applied to all images), you can create a new config file with a custom preset for it, then add a new script running the cli with |
So I solved the favicon, but won't the I think it would maybe make sense if the original filename was passed to https://github.com/vite-pwa/assets-generator/blob/main/src/utils.ts#L39C27-L39C27 |
You have 2 config files, last one with custom preset and run from command line with that custom file |
I'm a bit confused by response, say I have this:
When I run this, it will generate everything using |
If the favicon is generated with two.svg image, split your config file in 2 config files, the preset is global and cannot be shared between images. Keep the current configuration removIng two.svg image from it and create a new config file including only two.svg image. Update both config files to generate the pwa icons only in the current and favicons only in the new one. Add a new script to also run a new asset generation providing the new config file. |
Wondering if anybody can shed some light on how the images key would be useful as an array. Would this only be needed in the instance that you are customizing the names using
assetName
?I dug through the code and it looks like if the file already exists it will skip it, and since we can't assign a preset per image, i can't see how that would really be useful
My specific use case, I have an
svg
with a blue background i want to use for icon images, but not for favicon, so was trying to figure out how to generate the favicon separately.For now I just created my own preset and removed the
favicon
but would be nice if there was a way to do this automatically.The text was updated successfully, but these errors were encountered: