2
0
Files
bot/apps/builder/next.config.js
Baptiste Arnaud debdac12ff Introduce bot v2 in builder (#328)
Also, the new engine is the default for updated typebots for viewer

Closes #211
2023-02-21 15:25:14 +01:00

45 lines
1.0 KiB
JavaScript

/* eslint-disable @typescript-eslint/no-var-requires */
const { withSentryConfig } = require('@sentry/nextjs')
const path = require('path')
const withTM = require('next-transpile-modules')(['utils', 'models', 'emails'])
/** @type {import('next').NextConfig} */
const nextConfig = withTM({
reactStrictMode: true,
output: 'standalone',
experimental: {
outputFileTracingRoot: path.join(__dirname, '../../'),
},
headers: async () => {
return [
{
source: '/(.*)?',
headers: [
{
key: 'X-Frame-Options',
value: 'SAMEORIGIN',
},
],
},
]
},
})
const sentryWebpackPluginOptions = {
silent: true,
release: process.env.NEXT_PUBLIC_VERCEL_GIT_COMMIT_SHA + '-builder',
}
module.exports = process.env.NEXT_PUBLIC_SENTRY_DSN
? withSentryConfig(
{
...nextConfig,
sentry: {
hideSourceMaps: true,
widenClientFileUpload: true,
},
},
sentryWebpackPluginOptions
)
: nextConfig