From 5ee45f957db7c739425d7161fa2fabd7257d5f0e Mon Sep 17 00:00:00 2001 From: wonderlandpark Date: Mon, 31 May 2021 21:24:34 +0900 Subject: [PATCH] fix: only on production --- components/Advertisement.tsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/components/Advertisement.tsx b/components/Advertisement.tsx index 3fdea14..841714b 100644 --- a/components/Advertisement.tsx +++ b/components/Advertisement.tsx @@ -3,7 +3,7 @@ import Logger from '@utils/Logger' const Advertisement: React.FC = ({ size = 'short' }) => { useEffect(() => { - if (true) { + if (process.env.NODE_ENV === 'production') { window.adsbygoogle = window.adsbygoogle || [] try { window.adsbygoogle.push({}) @@ -19,11 +19,11 @@ const Advertisement: React.FC = ({ size = 'short' }) => { return
- {true ? ( + {process.env.NODE_ENV === 'production' ? (