Files
solisting/app/next.config.ts

20 lines
664 B
TypeScript

import type { NextConfig } from 'next'
const config: NextConfig = {
reactStrictMode: true,
transpilePackages: ['@solana/connector'],
// @solana/connector bundles a web3.js v1 compat layer for legacy wallets.
// We never pass web3.js Transaction objects (we use @solana/kit / Uint8Array),
// so this code path is dead. Stub the module so webpack doesn't error at build
// time when it can't resolve the optional dynamic import('@solana/web3.js').
webpack: (webpackConfig) => {
webpackConfig.resolve.fallback = {
...webpackConfig.resolve.fallback,
'@solana/web3.js': false,
}
return webpackConfig
},
}
export default config