diff options
| author | Furkan Sahin <furkan-dev@proton.me> | 2023-09-08 00:17:30 -0500 |
|---|---|---|
| committer | Furkan Sahin <furkan-dev@proton.me> | 2023-09-08 00:17:30 -0500 |
| commit | bdd8de9829102e3b0e85ded1c197647da1567f5a (patch) | |
| tree | 71997762fb6409cdeefb1c88ebe2bfe06c44628e /next.config.js | |
| parent | a61ffbc784d7c834c9ef483e36600fc5465b1dde (diff) | |
Add new export config, nextjs CLI/API change
Diffstat (limited to 'next.config.js')
| -rw-r--r-- | next.config.js | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/next.config.js b/next.config.js index b02506e..0d49eb4 100644 --- a/next.config.js +++ b/next.config.js @@ -1,7 +1,11 @@ const path = require('path'); const { withMarkdownLoader } = require('./plugins'); +const DISPLAY_DOMAIN = process.env.DISPLAY_DOMAIN; +if(!DISPLAY_DOMAIN) throw Error("Please define a display domain"); + +const exportDir = `export/${DISPLAY_DOMAIN}`; module.exports = () => { const plugins = [ @@ -16,7 +20,9 @@ module.exports = () => { includePaths: [path.join(__dirname, 'styles')] }, env: { - DISPLAY_DOMAIN: process.env.DISPLAY_DOMAIN || 'furkistan.com', - } + DISPLAY_DOMAIN: DISPLAY_DOMAIN, + }, + output: 'export', + distDir: exportDir, }; } |
