fix: wasm warning message, try optimizePackageImports on reaflow

This commit is contained in:
AykutSarac 2024-12-02 17:22:39 +03:00
parent 6608948e2e
commit b1c1989e60
No known key found for this signature in database

View File

@ -10,13 +10,20 @@ const config = {
output: "export",
reactStrictMode: false,
productionBrowserSourceMaps: true,
experimental: {
optimizePackageImports: ["reaflow"],
},
compiler: {
styledComponents: true,
},
webpack: config => {
webpack: (config, { isServer }) => {
config.resolve.fallback = { fs: false };
config.output.webassemblyModuleFilename = "static/wasm/[modulehash].wasm";
config.experiments = { asyncWebAssembly: true };
config.experiments = { asyncWebAssembly: true, layers: true };
if (!isServer) {
config.output.environment = { ...config.output.environment, asyncFunction: true };
}
return config;
},