-
Notifications
You must be signed in to change notification settings - Fork 12
Open
Description
Hello
Thank you for developing your product. I started using it to implement my projects.
I have the following question
I am using your Picture component from Minista
<Picture
className="news__img-two"
breakpoints={[1920]}
src="/src/assets/images/check-desktop.jpg"
artDirectives={[
{
media: `(min-width: 1920px)`,
src: "/src/assets/images/check-desktop.jpg",
formats: ['webp'],
breakpoints: [1920]
},
{
media: `(min-width: 1440px)`,
src: "/src/assets/images/check-laptop.jpg",
formats: ['webp'],
breakpoints: [1440]
},
{
media: `(min-width: 375px)`,
src: "/src/assets/images/check-mobile.jpg",
formats: ['webp'],
breakpoints: [375]
}
]}
alt="check" />In the build I get names with their sizes, for example check-desktop-1920x595.webp,
Is there any way to not add their sizes to the file name?
I tried to do this through the settings, but it didn't help me
export default defineConfig({
assets: {
outDir: 'assets',
outName: '[name]',
images: {
outDir: 'assets/images',
outName: '[name][extname]', `this`
...I also tried to do it inside the Vite configuration, but still not working
vite: {
resolve: {
extensions: ['.js', '.ts', '.tsx', '.jsx'],
},
build: {
rollupOptions: {
output: {
assetFileNames: `assets/images/[name][ext]`, `this`
chunkFileNames: `assets/[name].js`,
},
},
},
},Is there any way to not add the image size to the name?
Metadata
Metadata
Assignees
Labels
No labels