Skip to content

Commit

Permalink
update config/naming
Browse files Browse the repository at this point in the history
  • Loading branch information
corlard3y committed Sep 4, 2024
1 parent f83c31f commit 9066bcd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions basePath.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
function getPreviewBasePath() {
if (typeof process !== 'undefined' && process.env) {
// Node.js environment (e.g., during the build process)
return process.env.REACT_APP_PR_PREVIEW_BASE
? `/push-website/pr-preview/${process.env.REACT_APP_PR_PREVIEW_BASE}`
return process.env.REACT_APP_PREVIEW_BASE
? `/push-website/pr-preview/${process.env.REACT_APP_PREVIEW_BASE}`
: '';
}
return '';
Expand Down
4 changes: 2 additions & 2 deletions docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const lightCodeTheme = require('prism-react-renderer').themes.dracula;
const darkCodeTheme = require('prism-react-renderer').themes.dracula;

// Determine if we're in production or preview mode
const isProd = process.env.DEPLOY_ENV === 'prod';
const isProd = process.env.REACT_APP_PREVIEW_BASE === undefined;

/** @type {import('@docusaurus/types').Config} */
const config = {
Expand All @@ -18,7 +18,7 @@ const config = {
// Set the baseUrl depending on the environment
baseUrl: isProd
? '/'
: `/push-website/pr-preview/${process.env.REACT_APP_PR_PREVIEW_BASE}/`,
: `/push-website/pr-preview/${process.env.REACT_APP_PREVIEW_BASE}/`,
trailingSlash: true,

// GitHub pages deployment config.
Expand Down

0 comments on commit 9066bcd

Please sign in to comment.