Turbopack source-maps
Unanswered
Sun bear posted this in #help-forum
Sun bearOP
Not getting the right
With turbo (

Without turbo (

When I use turbo I am not getting the right component, only the bundled version.
Current
With turbo (
pnpm dev --turbo
)
Without turbo (
pnpm dev
):
When I use turbo I am not getting the right component, only the bundled version.
Current
next.config
:/** @type {import('next').NextConfig} */
const nextConfig = {
experimental: {
serverActions: {
bodySizeLimit: '100mb', // Bump body size limit to 100 in order to send very large orders via email (TODO: upload them in the future)
},
// https://community.vercel.com/t/troubleshooting-builds-failing-with-sigkill-or-out-of-memory-errors/156
webpackBuildWorker: true,
},
eslint: {
ignoreDuringBuilds: true,
},
typescript: {
ignoreBuildErrors: true,
},
env: {
NEXT_PUBLIC_SENTRY_RELEASE: process.env.NEXT_PUBLIC_SENTRY_RELEASE,
},
// Memory optimization
productionBrowserSourceMaps: true,
webpack: (config, { dev, isServer }) => {
if (config.cache && !dev) {
config.cache = Object.freeze({
type: 'memory',
});
}
if (isServer) {
config.devtool = 'source-map';
}
// Important: return the modified config
return config;
},
// PostHog rewrites to avoid ad-blockers
async rewrites() {
return [
{
source: '/ingest/static/:path*',
destination: 'https://us-assets.i.posthog.com/static/:path*',
},
{
source: '/ingest/:path*',
destination: 'https://us.i.posthog.com/:path*',
},
{
source: '/ingest/decide',
destination: 'https://us.i.posthog.com/decide',
},
];
},
// This is required to support PostHog trailing slash API requests
skipTrailingSlashRedirect: true,
};