Skip to content

Commit

Permalink
Remove ads
Browse files Browse the repository at this point in the history
  • Loading branch information
jumpalottahigh committed Feb 23, 2020
1 parent dbac4b1 commit 8652039
Show file tree
Hide file tree
Showing 9 changed files with 9 additions and 80 deletions.
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@
"gatsby-transformer-sharp": "^2.3.12",
"google-map-react": "^1.1.5",
"react": "^16.12.0",
"react-adsense": "^0.1.0",
"react-dom": "^16.12.0",
"react-helmet": "^5.2.1",
"react-icons": "^3.8.0",
Expand Down
22 changes: 1 addition & 21 deletions src/pages/blog/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import styled from 'styled-components'
import { Link, graphql } from 'gatsby'
import Helmet from 'react-helmet'
import Img from 'gatsby-image'
import AdSense from 'react-adsense'

import Layout from '../../components/Layout/layout'
import PaperCard from '../../components/UI/PaperCard'
Expand Down Expand Up @@ -74,17 +73,7 @@ class BlogIndexPage extends React.Component {
>
{posts.map(({ node }, index) => {
const title = node.frontmatter.title || node.fields.slug
return index > 0 && index % 4 === 0 ? (
<StyledPaperCard key={index}>
<AdSense.Google
client="ca-pub-8470358888871889"
slot="6212610784"
style={{ display: 'block' }}
format="fluid"
layoutKey="-5w+bz-1z-4l+vv"
/>
</StyledPaperCard>
) : (
return (
<StyledBlogLink key={node.fields.slug} to={node.fields.slug}>
<StyledPaperCard hoverable="true" style={{ height: '100%' }}>
{node.frontmatter.ogImage !== null && (
Expand All @@ -105,15 +94,6 @@ class BlogIndexPage extends React.Component {
</StyledBlogLink>
)
})}
<StyledPaperCard>
<AdSense.Google
client="ca-pub-8470358888871889"
slot="6212610784"
style={{ display: 'block' }}
format="fluid"
layoutKey="-5w+bz-1z-4l+vv"
/>
</StyledPaperCard>
</Grid>
</Layout>
)
Expand Down
10 changes: 0 additions & 10 deletions src/pages/fpv-map.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import React from 'react'
import Helmet from 'react-helmet'
import { graphql } from 'gatsby'
import AdSense from 'react-adsense'
import Layout from '../components/Layout/layout'
import Map from '../components/Map/Map'

Expand Down Expand Up @@ -29,15 +28,6 @@ const FPVMapPage = ({ data }) => (
]}
/>
<Map markers={data.allContentfulMapMarkers.edges} />

<AdSense.Google
client="ca-pub-8470358888871889"
slot="7225507221"
style={{ display: 'block' }}
format="auto"
responsive="true"
layoutKey="-gw-1+2a-9x+5c"
/>
</Layout>
)

Expand Down
10 changes: 0 additions & 10 deletions src/pages/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import React from 'react'
import styled from 'styled-components'
import { graphql, Link } from 'gatsby'
import Helmet from 'react-helmet'
import AdSense from 'react-adsense'

import Layout from '../components/Layout/layout'
import PaperCard from '../components/UI/PaperCard'
Expand Down Expand Up @@ -361,15 +360,6 @@ class IndexPage extends React.Component {
<br />
Stay tuned and enjoy!
</p>

<AdSense.Google
client="ca-pub-8470358888871889"
slot="7225507221"
style={{ display: 'block' }}
format="auto"
responsive="true"
layoutKey="-gw-1+2a-9x+5c"
/>
</div>
</Layout>
)
Expand Down
10 changes: 0 additions & 10 deletions src/pages/weather.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import React from 'react'
import Helmet from 'react-helmet'
import AdSense from 'react-adsense'

import Layout from '../components/Layout/layout'
import PaperCard from '../components/UI/PaperCard'
Expand Down Expand Up @@ -36,15 +35,6 @@ const WeatherPage = () => (
<PaperCard>
<WeatherInfo />
</PaperCard>

<AdSense.Google
client="ca-pub-8470358888871889"
slot="7225507221"
style={{ display: 'block' }}
format="auto"
responsive="true"
layoutKey="-gw-1+2a-9x+5c"
/>
</Layout>
)

Expand Down
31 changes: 8 additions & 23 deletions src/templates/blog-post.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import React from 'react'
import styled from 'styled-components'
import { graphql } from 'gatsby'
import Helmet from 'react-helmet'
import AdSense from 'react-adsense'

import Layout from '../components/Layout/layout'
import PromoBanner from '../components/UI/PromoBanner'
Expand All @@ -29,37 +28,23 @@ class BlogPostTemplate extends React.Component {
)}
</Helmet>
<h1>{post.frontmatter.title}</h1>
{/* <PromoBanner
<PromoBanner
linkTo="https://www.banggood.com/promotion-banggood-2019-summer-prime-sale-9178.html?utmid=8617&p=NY211410857261201705"
imagePath="/promo/banggood-summer-prime-sale-2019.png"
/> */}
<AdSense.Google
client="ca-pub-8470358888871889"
slot="6212610784"
style={{ display: 'block' }}
format="fluid"
layoutKey="-5w+bz-1z-4l+vv"
imagePath="/promo/banggood-stripe-4.jpg"
/>
<p>
{post.frontmatter.author}, {post.frontmatter.date}
</p>
<BlogContent dangerouslySetInnerHTML={{ __html: post.html }} />
<hr />
<AdSense.Google
client="ca-pub-8470358888871889"
slot="6212610784"
style={{ display: 'block' }}
format="fluid"
layoutKey="-5w+bz-1z-4l+vv"
/>
{/* <PromoBanner
<PromoBanner
linkTo="https://www.banggood.com/promotion-2019-summer-rc-outdoor-sale-promotion-9166.html?utmid=8759&utm_design=80&p=NY211410857261201705"
imagePath="/promo/banggood-rc-july-2019.jpg"
/> */}
{/* <PromoBanner
imagePath="/promo/banggood-stripe-4.jpg"
/>
<PromoBanner
linkTo="https://www.banggood.com/promotion-banggood-2019-summer-prime-sale-9178.html?utmid=8617&p=NY211410857261201705"
imagePath="/promo/banggood-summer-sale-2019.jpg"
/> */}
imagePath="/promo/banggood-square.jpg"
/>
</Layout>
)
}
Expand Down
Binary file added static/promo/banggood-square.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/promo/banggood-stripe-4.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 0 additions & 5 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -10626,11 +10626,6 @@ rc@^1.2.7, rc@^1.2.8:
minimist "^1.2.0"
strip-json-comments "~2.0.1"

react-adsense@^0.1.0:
version "0.1.0"
resolved "https://registry.yarnpkg.com/react-adsense/-/react-adsense-0.1.0.tgz#f170007a9ab05ee2cd1c915cdc9788624658e3c1"
integrity sha512-VzGMH9qA7bBKAveK1joFWphhB7e2Y1ToSGzUa8b7eit3+VSkg/2MSvKxe5d/r4mcmkOHu6CHNJW0nn6RQC3IZA==

react-dev-utils@^4.2.3:
version "4.2.3"
resolved "https://registry.yarnpkg.com/react-dev-utils/-/react-dev-utils-4.2.3.tgz#5b42d9ea58d5e9e017a2f57a40a8af408a3a46fb"
Expand Down

0 comments on commit 8652039

Please sign in to comment.