Skip to content
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

enhanced-img: Support configuring vite-imagetools (e.g. removeMetadata=false) #13085

Open
SpraxDev opened this issue Dec 1, 2024 · 0 comments
Labels

Comments

@SpraxDev
Copy link

SpraxDev commented Dec 1, 2024

Describe the problem

I would like to keep the exif metadata information stored in my images, but when using enhanced-img, these are removed by-default.

vite-imagetools supports removeMetadata which is true by default (which I think is a good default).

Describe the proposed solution

accept a list of options in

export function enhancedImages() {

that might be passed into vite-imagetools:

function imagetools_plugin() {
/** @type {Partial<import('vite-imagetools').VitePluginOptions>} */
const imagetools_opts = {

You might not want to just accept all options and just blindly pass them to vite-imagetool, but maybe a list of sensible parameters might make sense.

Alternatives considered

I couldn't find any alternative while sticking with sveltejs/enhanced-img.
I'd need to switch to another package

Importance

nice to have

Additional Information

Remeber to delete node_modules/.cache/imagetools, when testing the removeMetadata option.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants