diff --git a/next.config.js b/next.config.js deleted file mode 100644 index 5f7b4b6..0000000 --- a/next.config.js +++ /dev/null @@ -1,25 +0,0 @@ -// @ts-check -const { PHASE_DEVELOPMENT_SERVER } = require('next/constants'); - -module.exports = async (phase) => { - if (phase === PHASE_DEVELOPMENT_SERVER) { - /** - * @type {import('next').NextConfig} - */ - const nextConfig = { - reactStrictMode: true, - output: 'export', - }; - return nextConfig; - } - - /** - * @type {import('next').NextConfig} - */ - const nextConfig = { - reactStrictMode: true, - output: 'export', - basePath: '/auto-manufacturers', // GitHub pages - }; - return nextConfig; -}; diff --git a/next.config.ts b/next.config.ts index 5e891cf..cf7bcde 100644 --- a/next.config.ts +++ b/next.config.ts @@ -1,7 +1,26 @@ +import { PHASE_DEVELOPMENT_SERVER } from 'next/constants'; + import type { NextConfig } from 'next'; -const nextConfig: NextConfig = { - /* config options here */ -}; +export default async (phase: string) => { + if (phase === PHASE_DEVELOPMENT_SERVER) { + /** + * @type {import('next').NextConfig} + */ + const nextConfig: NextConfig = { + reactStrictMode: true, + output: 'export', + }; + return nextConfig; + } -export default nextConfig; + /** + * @type {import('next').NextConfig} + */ + const nextConfig: NextConfig = { + reactStrictMode: true, + output: 'export', + basePath: '/auto-manufacturers', // GitHub pages + }; + return nextConfig; +};