Skip to content

Commit

Permalink
Update App.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
howardchung authored Nov 18, 2024
1 parent c4a9b6f commit 8cb58ae
Showing 1 changed file with 1 addition and 24 deletions.
25 changes: 1 addition & 24 deletions src/components/App/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -168,12 +168,6 @@ const App = (props: AppProps) => {

const includeAds = !['/', '/api-keys', '/status'].includes(location.pathname);

React.useEffect(() => {
if (includeAds) {
(window.adsbygoogle = window.adsbygoogle || []).push({});
}
}, []);

return (
// @ts-ignore
<MuiThemeProvider muiTheme={getMuiTheme(darkBaseTheme, muiTheme)}> {/* muiTheme types are missing here */}
Expand All @@ -186,15 +180,6 @@ const App = (props: AppProps) => {
/>
<Header location={location} />
<StyledBodyDiv {...props}>
<AdBannerDiv>
{includeAds && config.VITE_ENABLE_ADSENSE && (
<ins
className="adsbygoogle"
style={{ display: 'block', width: 728, height: 90, margin: 'auto' }}
data-ad-client="ca-pub-5591574346816667"
data-ad-slot="9789745633"
/>)}
</AdBannerDiv>
<Switch>
<Route exact path="/" component={Home} />
<Route exact path="/matches/:matchId?/:info?" component={Matches} />
Expand Down Expand Up @@ -236,14 +221,6 @@ const App = (props: AppProps) => {
</div>
</div>
)}
{includeAds && config.VITE_ENABLE_ADSENSE && (
<ins
className="adsbygoogle"
style={{ display: 'block', width: 728, height: 90, margin: 'auto' }}
data-ad-client="ca-pub-5591574346816667"
data-ad-slot="7739169508"
/>
)}
</AdBannerDiv>
<Footer />
<Back2Top
Expand All @@ -270,4 +247,4 @@ const mapStateToProps = (state: any) => ({
});

// @ts-ignore
export default connect(mapStateToProps)(withRouter(App)); // property 'strings' is missing in type
export default connect(mapStateToProps)(withRouter(App)); // property 'strings' is missing in type

0 comments on commit 8cb58ae

Please sign in to comment.