dailycheckin/docs/next.config.js
shitao 06cd1b0664 新增(docs):添加文档
 新增(docs-publish.yml):添加GitHub Actions工作流程,自动部署文档
  🔧 更新(.gitignore):忽略.next和node_modules文件夹
2024-02-20 09:11:25 +08:00

26 lines
515 B
JavaScript

/** @type {import('next').NextConfig} */
const withNextra = require('nextra')({
theme: 'nextra-theme-docs',
themeConfig: './theme.config.tsx',
})
const isProduction = process.env.NODE_ENV === 'production'
const assetPrefix = isProduction ? '/dailycheckin' : ''
const nextConfig = {
images: {
unoptimized: true,
},
reactStrictMode: true,
swcMinify: true,
trailingSlash: true,
assetPrefix,
basePath: assetPrefix,
output: 'export',
}
module.exports = {
...withNextra(),
...nextConfig,
}