Skip to content

Commit

Permalink
Exclude ooni run previews from indexing (#211)
Browse files Browse the repository at this point in the history
  • Loading branch information
majakomel authored Feb 13, 2025
1 parent 7b57390 commit 95f6392
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,21 @@ module.exports = withBundleAnalyzer(
locales: getSupportedLanguages(),
defaultLocale: DEFAULT_LOCALE,
},
async headers() {
const headers = []
if (process.env.NEXT_PUBLIC_VERCEL_ENV === 'preview') {
headers.push({
headers: [
{
key: 'X-Robots-Tag',
value: 'noindex',
},
],
source: '/:path*',
})
}
return headers
},
async rewrites() {
return [
{
Expand Down

0 comments on commit 95f6392

Please sign in to comment.