-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathnext.config.mjs
More file actions
30 lines (25 loc) ยท 1.17 KB
/
next.config.mjs
File metadata and controls
30 lines (25 loc) ยท 1.17 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
import bundleAnalyzer from '@next/bundle-analyzer';
import { createVanillaExtractPlugin } from '@vanilla-extract/next-plugin';
import path from 'path';
import { fileURLToPath } from 'url';
const __dirname = path.dirname(fileURLToPath(import.meta.url));
const withBundleAnalyzer = bundleAnalyzer({
enabled: process.env.ANALYZE === 'true',
});
const withVanillaExtract = createVanillaExtractPlugin({
identifiers: 'debug', // ๊ธฐ์กด Vite ์ค์ ๊ณผ ๋์ผ (short | debug | custom)
});
/** @type {import('next').NextConfig} */
const nextConfig = {
// output: 'export', // Single-Page Application (SPA) ์ถ๋ ฅ.
basePath: process.env.NEXT_PUBLIC_BASE_PATH || '',
// ์์ ํด๋ lockfile๊ณผ ๊ตฌ๋ถํด ์ด ํ๋ก์ ํธ๋ฅผ ๋ฃจํธ๋ก ์ฌ์ฉ (๊ฒฝ๊ณ ์ ๊ฑฐ)
outputFileTracingRoot: __dirname,
// src/pages๋ SPA(react-router) ์ปดํฌ๋ํธ์ด๋ฏ๋ก Pages Router๋ก ๊ฒ์ฆํ์ง ์๋๋ก ๋นํ์ฑํ
typedRoutes: false,
eslint: {
// ๋ง์ด๊ทธ๋ ์ด์
๋จ๊ณ์์ ๊ธฐ์กด a11y/ํ
๊ท์น์ผ๋ก ๋น๋ ์คํจํ์ง ์๋๋ก ๋ฌด์ (์ถํ ๊ท์น ์์ ํ ์ ๊ฑฐ ๊ถ์ฅ)
ignoreDuringBuilds: true,
},
};
export default withBundleAnalyzer(withVanillaExtract(nextConfig));