Skip to content

Commit

Permalink
fix(storefront): Fixing imports to mime/lite with mime v4
Browse files Browse the repository at this point in the history
  • Loading branch information
leomp12 committed Apr 1, 2024
1 parent 105c16c commit 76b91f5
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions packages/eslint/base.eslintrc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ module.exports = {
'astro/middleware',
'unocss/astro',
'unplugin-auto-import/astro',
'mime/lite',
'@@.*',
'content/.*',
'~/.*',
Expand Down
2 changes: 1 addition & 1 deletion packages/storefront/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -78,4 +78,4 @@
"@cloudcommerce/types": "workspace:*",
"@types/react": "^18.2.73"
}
}
}
2 changes: 1 addition & 1 deletion packages/storefront/src/images/picture-base.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type { HTMLAttributes } from 'astro/types';
import type { OutputFormat, TransformOptions, GetBuiltImage } from './get-built-image';
import mime from 'mime/lite.js';
import mime from 'mime/lite';

export interface GetPictureParams {
src: string /* | ImageMetadata | Promise<{ default: ImageMetadata }> */;
Expand Down
2 changes: 1 addition & 1 deletion packages/storefront/src/lib/components/Picture.astro
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import type { ImageMetadata } from 'astro';
import { resolve as resolvePath, basename } from 'node:path';
import { copyFileSync } from 'node:fs';
import mime from 'mime/lite.js';
import mime from 'mime/lite';
import { getImage } from 'astro:assets';
import imageSize from 'image-size';
import { createPictureGetter } from '../../images/picture-base';
Expand Down

0 comments on commit 76b91f5

Please sign in to comment.