File size: 541 Bytes
e7ef6c8 |
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 |
const isGithubActions = process.env.GITHUB_ACTIONS || false
let assetPrefix = 'docs'
let basePath = 'docs/'
if (isGithubActions) {
const repo = process.env.GITHUB_REPOSITORY.replace(/.*?\//, '')
assetPrefix = `/${repo}/docs/`
basePath = `/${repo}/docs`
}
const withNextra = require('nextra')({
theme: 'nextra-theme-docs',
themeConfig: './theme.config.tsx',
assetPrefix: assetPrefix,
basePath: basePath,
images: {
loader: 'imgix',
path: 'the "domain" of your Imigix source',
},
})
module.exports = withNextra()
|