kucrut/vite-for-wp

Image asset support

Closed this issue · 1 comments

Hi,

I have some images that are just regular imports with Vite. Any plans for adding support for these other file types?

I could try writing a PR to create this, I assume it would be similar to the way CSS files are loaded currently (the .webp file I'm loading is listed in the manifest.json for example). My suggested implementation would be to add an option to specify additional file type extensions (or a regex match) that are considered an asset.

Nevermind, it is working properly, Gulp was corrupting my images when copying/building the plugin artifact.
Great library by the way, incredible how it works as flawlessly as it does!