Skip to content
This repository has been archived by the owner on Oct 26, 2024. It is now read-only.

Commit

Permalink
fix: update env
Browse files Browse the repository at this point in the history
  • Loading branch information
kjxbyz committed Oct 30, 2023
1 parent 2dfe578 commit a0f59dd
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/.env.example
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ NEXT_PUBLIC_GOOGLE_ID=
NEXT_PUBLIC_GH_TOKEN=
NEXT_PUBLIC_GH_REPO_OWNER=
NEXT_PUBLIC_GH_REPO=
NEXT_PUBLIC_COOKIE_BANNER_ID=
2 changes: 2 additions & 0 deletions docs/components/shared/cookie-banner.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ import { LngProps } from "@/i18next-lng";
const CookieBanner = (props: LngProps) => {
const NEXT_PUBLIC_COOKIE_BANNER_ID = process.env.NEXT_PUBLIC_COOKIE_BANNER_ID;

if (!NEXT_PUBLIC_COOKIE_BANNER_ID) return null;

return (
<>
<Script
Expand Down
2 changes: 2 additions & 0 deletions docs/components/shared/google-analytics.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ import Script from "next/script";
const GoogleAnalytics = () => {
const GA_TRACKING_ID = process.env.NEXT_PUBLIC_GOOGLE_ID;

if (!GA_TRACKING_ID) return null;

return (
<>
<Script
Expand Down
1 change: 1 addition & 0 deletions docs/next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ const nextConfig = {
NEXT_PUBLIC_GH_TOKEN: process.env.NEXT_PUBLIC_GH_TOKEN,
NEXT_PUBLIC_GH_REPO_OWNER: process.env.NEXT_PUBLIC_GH_REPO_OWNER,
NEXT_PUBLIC_GH_REPO: process.env.NEXT_PUBLIC_GH_REPO,
NEXT_PUBLIC_COOKIE_BANNER_ID: process.env.NEXT_PUBLIC_COOKIE_BANNER_ID,
},
};

Expand Down
1 change: 1 addition & 0 deletions docs/process.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,6 @@ declare namespace NodeJS {
NEXT_PUBLIC_GH_TOKEN: string;
NEXT_PUBLIC_GH_REPO_OWNER: string;
NEXT_PUBLIC_GH_REPO: string;
NEXT_PUBLIC_COOKIE_BANNER_ID: string;
}
}

1 comment on commit a0f59dd

@vercel
Copy link

@vercel vercel bot commented on a0f59dd Oct 30, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.