From 69927dfcabbd3beb91f333def8df2e497a49a8be Mon Sep 17 00:00:00 2001 From: Manuel Date: Wed, 7 Jun 2023 21:11:32 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=9A=91=20ES=20module=20dependencies?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .eslintrc.js | 1 + next.config.js | 14 -------------- next.config.mjs | 17 +++++++++++++++++ package.json | 2 +- tsconfig.json | 4 ++-- 5 files changed, 21 insertions(+), 17 deletions(-) delete mode 100644 next.config.js create mode 100644 next.config.mjs diff --git a/.eslintrc.js b/.eslintrc.js index 710ccb1ac9c..6955f5f7fc1 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -31,6 +31,7 @@ module.exports = { '@typescript-eslint/no-non-null-assertion': 'off', 'no-continue': 'off', 'linebreak-style': 0, + 'import/extensions': 'off', 'vitest/max-nested-describe': [ 'error', { diff --git a/next.config.js b/next.config.js deleted file mode 100644 index dde3ec97744..00000000000 --- a/next.config.js +++ /dev/null @@ -1,14 +0,0 @@ -const { i18n } = require('./next-i18next.config'); - -const withBundleAnalyzer = require('@next/bundle-analyzer')({ - enabled: process.env.ANALYZE === 'true', -}); - -module.exports = withBundleAnalyzer({ - images: { - domains: ['cdn.jsdelivr.net'], - }, - reactStrictMode: true, - output: 'standalone', - i18n, -}); diff --git a/next.config.mjs b/next.config.mjs new file mode 100644 index 00000000000..e082b47994b --- /dev/null +++ b/next.config.mjs @@ -0,0 +1,17 @@ +const { i18n } = await import('./next-i18next.config.js'); + +const { default: configreBundleAnalyser } = await import('@next/bundle-analyzer'); + +const withBundleAnalyzer = configreBundleAnalyser({ + enabled: process.env.ANALYZE === 'true', +}); + +export default withBundleAnalyzer({ + images: { + domains: ['cdn.jsdelivr.net'], + }, + reactStrictMode: true, + output: 'standalone', + i18n, + transpilePackages: ['@jellyfin/sdk'], +}); diff --git a/package.json b/package.json index 1989db62399..98a8bc71487 100644 --- a/package.json +++ b/package.json @@ -143,4 +143,4 @@ "automerge": true } } -} \ No newline at end of file +} diff --git a/tsconfig.json b/tsconfig.json index 0255f1da95c..df921ddfafb 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -28,10 +28,10 @@ "next-env.d.ts", "**/*.ts", "**/*.tsx", - "next.config.js", + "next.config.mjs", ".next/types/**/*.ts" ], "exclude": [ "node_modules" ] -} \ No newline at end of file +}