diff --git a/next.config.ts b/next.config.ts index 78947e8..1cf8c6b 100644 --- a/next.config.ts +++ b/next.config.ts @@ -80,6 +80,14 @@ const nextConfig: NextConfig = { ], }, webpack: (config, { isServer }) => { + if (isServer) { + config.externals = [ + ...(config.externals || []), + { + canvas: 'commonjs @napi-rs/canvas', + }, + ]; + } if (isServer && bundleWorkerCompute) { config.resolve.alias = { ...(config.resolve.alias || {}),