richardtallent / vite-plugin-singlefile

Vite plugin for inlining JavaScript and CSS resources
MIT License
810 stars 53 forks source link

Inlining other assets as SVG's, PNG's and TTF's #48

Closed interacsion closed 2 years ago

interacsion commented 2 years ago

Title is self explanatory. any plans to implement something like this?

richardtallent commented 2 years ago

Since part of using this plug-in entails setting the "assetsInlineLimit" ridiculously high, all imported binary files in the Assets folder should be inlined as base64 data URLs, which means they will end up in the final HTML bundle.

Details:

https://vitejs.dev/guide/assets.html