mirror of https://github.com/VERT-sh/VERT.git
fix: fix AVIF/JXL support
we need to copy the vips-*.wasm files from node_modules into vite's workers folder
This commit is contained in:
parent
e9ea02198f
commit
582f99588f
|
@ -34,8 +34,8 @@ export class VipsConverter extends Converter {
|
|||
".tiff",
|
||||
".jfif",
|
||||
//".heif", HEIF files that are encoded like HEIC files (and HEIC files in general) aren't supported due to https://github.com/kleisauke/wasm-vips/issues/3
|
||||
//".avif", there is an issue with vite not bundling the wasm-vips' dynamicLibraries wasm files correctly
|
||||
//".jxl",
|
||||
".avif",
|
||||
".jxl",
|
||||
];
|
||||
|
||||
public readonly reportsProgress = false;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import Vips from "wasm-vips";
|
||||
|
||||
const vipsPromise = Vips({ dynamicLibraries: [] });
|
||||
const vipsPromise = Vips();
|
||||
|
||||
vipsPromise
|
||||
.then(() => {
|
||||
|
|
|
@ -38,6 +38,10 @@ export default defineConfig({
|
|||
src: "_headers",
|
||||
dest: "",
|
||||
},
|
||||
{
|
||||
src: "node_modules/wasm-vips/lib/vips-*.wasm",
|
||||
dest: "_app/immutable/workers",
|
||||
},
|
||||
],
|
||||
}),
|
||||
],
|
||||
|
|
Loading…
Reference in New Issue