Skip to content

Commit

Permalink
♻️ Use @nuxtjs/google-adsense for Adsense
Browse files Browse the repository at this point in the history
  • Loading branch information
williamchong committed Dec 14, 2024
1 parent 46efd0e commit 493e607
Show file tree
Hide file tree
Showing 3 changed files with 481 additions and 11 deletions.
26 changes: 17 additions & 9 deletions nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,24 +2,32 @@
export default defineNuxtConfig({
app: {
head: {
title: 'CBOR to JSON Online Converter',
title: "CBOR to JSON Online Converter",
meta: [
{ name: 'og:title', content: 'CBOR to JSON Online Converter' },
{ name: 'description', content: 'Easily convert data between CBOR (Concise Binary Object Representation) and JSON (JavaScript Object Notation) formats with this online web decoder.' }
{ name: "og:title", content: "CBOR to JSON Online Converter" },
{
name: "description",
content:
"Easily convert data between CBOR (Concise Binary Object Representation) and JSON (JavaScript Object Notation) formats with this online web decoder.",
},
],
link: [
{ rel: 'preload', as: 'script', href: 'https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-5384552213891537', crossorigin: 'anonymous' },
{ rel: 'preload', as: 'script', href: 'https://www.googletagmanager.com/gtag/js?id=G-PG6KXFFZPF' },
],
script: [
{ src: 'https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-5384552213891537', async: true, crossorigin: 'anonymous', body: true },
{
rel: "preload",
as: "script",
href: "https://www.googletagmanager.com/gtag/js?id=G-PG6KXFFZPF",
},
],
},
},
modules: ["nuxt-gtag"],
modules: ["nuxt-gtag", "@nuxtjs/google-adsense"],
gtag: {
id: "G-PG6KXFFZPF",
},
googleAdsense: {
id: "ca-pub-5384552213891537",
onPageLoad: true,
},
devtools: { enabled: true },
experimental: {
clientNodeCompat: true,
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"postinstall": "nuxt prepare"
},
"dependencies": {
"@nuxtjs/google-adsense": "^3.0.0",
"cbor-x": "^1.5.9",
"nuxt": "^3.12.2",
"nuxt-gtag": "^2.0.6",
Expand Down
Loading

0 comments on commit 493e607

Please sign in to comment.