Skip to content

Commit

Permalink
Rename BASE_PATH to NEXT_PUBLIC_BASE_PATH
Browse files Browse the repository at this point in the history
  • Loading branch information
otobot1 committed Oct 26, 2023
1 parent 698130b commit 97c2ecf
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

# next.js base path
# https://nextjs.org/docs/app/api-reference/next-config-js/basePath
BASE_PATH=""
NEXT_PUBLIC_BASE_PATH=""

# Prisma
# https://www.prisma.io/docs/reference/database-reference/connection-urls#env
Expand Down
2 changes: 1 addition & 1 deletion next.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

/** @type {import("next").NextConfig} */
const config = {
basePath: process.env.BASE_PATH,
basePath: process.env.NEXT_PUBLIC_BASE_PATH,
reactStrictMode: true,
images: { //TODO!: figure out how to fix crash on next.config.mjs change
remotePatterns: [
Expand Down
2 changes: 1 addition & 1 deletion src/components/layout/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ export const Layout = ({
/>
</Head>
<BackgroundImage
src={`${process.env.BASE_PATH}/images/cml_background1.png`}
src={`${process.env.NEXT_PUBLIC_BASE_PATH}/images/cml_background1.png`}
className={classes.backgroundImage}
>
<Grid gutter="0">
Expand Down
2 changes: 1 addition & 1 deletion src/pages/_app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const MyApp: AppType<{ session: Session | null; }> = ({
pageProps: { session, ...pageProps },
}) => {
return (
<SessionProvider session={session} basePath={process.env.BASE_PATH}>
<SessionProvider session={session} basePath={process.env.NEXT_PUBLIC_BASE_PATH}>
<MantineProvider
emotionCache={emotionCache}
withGlobalStyles
Expand Down

0 comments on commit 97c2ecf

Please sign in to comment.