darkobits / vite-plugin-favicons

💅 Generate favicons for your Vite project.
Other
8 stars 1 forks source link

manifest.json doesn't match with the file names generated by vite #1

Closed drgarlic closed 2 years ago

drgarlic commented 3 years ago

For example the manifest will list /android-chrome-144x144.png while the actual path is /android-chrome-144x144.d50baba5.png

darkobits commented 3 years ago

The issue here seems to be the same one we have to address with the HTML favicons generates; it doesn't know the final file name generated by Vite according to the configured assetFileNames option, which may include a hash or other tokens. The fix will likely be to take the same approach and iterate through the manifests favicons generates and replace each referenced file with the final filename we get from Vite.

I'd probably like to find a way to factor-out and generalize some of the logic that's already doing this for HTML tags.

Thanks for finding (and reporting!) this issue, I'll try to get to it as soon as time allows.

drgarlic commented 2 years ago

Hi !

Any news with this bug ? It breaks sadly the whole purpose of this plugin and makes it unusable..

darkobits commented 2 years ago

This should be fixed in cb0d692f4be4be81b195079dc14a0b1f02801f0d. Give version 0.1.6 a try and if the problem persists, feel free to re-open this issue.

Thank you for your patience on this, I've been extremely busy. 😅