From 42ace0afcbb14c4671bb6bc3ef30510ad642c424 Mon Sep 17 00:00:00 2001 From: Chance Strickland Date: Tue, 3 Feb 2026 07:59:32 -0800 Subject: [PATCH] Use ESM for next.config --- .prettierignore | 1 + apps/playground/{next.config.js => next.config.mjs} | 6 +++++- apps/playground/package.json | 2 +- 3 files changed, 7 insertions(+), 2 deletions(-) rename apps/playground/{next.config.js => next.config.mjs} (66%) diff --git a/.prettierignore b/.prettierignore index 801150a70..b2c92093b 100644 --- a/.prettierignore +++ b/.prettierignore @@ -12,3 +12,4 @@ packages/radix-ui-themes/utilities.css packages/radix-ui-themes/tokens.css packages/radix-ui-themes/layout.css apps/playground/playwright-report +apps/playground/test-results diff --git a/apps/playground/next.config.js b/apps/playground/next.config.mjs similarity index 66% rename from apps/playground/next.config.js rename to apps/playground/next.config.mjs index d598cb6ba..05b43e983 100644 --- a/apps/playground/next.config.js +++ b/apps/playground/next.config.mjs @@ -1,7 +1,11 @@ +// @ts-check +import path from 'node:path'; + /** @type {import('next').NextConfig} */ const nextConfig = { reactStrictMode: true, transpilePackages: ['@radix-ui/themes'], + outputFileTracingRoot: path.resolve(import.meta.dirname, '../..'), async redirects() { return [ { @@ -13,4 +17,4 @@ const nextConfig = { }, }; -module.exports = nextConfig; +export default nextConfig; diff --git a/apps/playground/package.json b/apps/playground/package.json index c2fd10c3c..24aa95163 100644 --- a/apps/playground/package.json +++ b/apps/playground/package.json @@ -6,7 +6,7 @@ "dev": "next dev", "build": "next build", "start": "next start", - "clean": "rm -rf node_modules .next .turbo", + "clean": "rm -rf node_modules .next .turbo playwright-report test-results", "lint": "tsc --noEmit", "test:vr": "playwright test", "test:vr:ui": "playwright test --ui",