From 1be9b6f74c748241f24c329406c623957f7c27e2 Mon Sep 17 00:00:00 2001 From: Colby Fayock Date: Fri, 12 Apr 2024 11:29:48 -0300 Subject: [PATCH] Step 1: Installing and configuring Plausible --- app/layout.tsx | 4 ++++ package-lock.json | 29 +++++++++++++++++++++++++++++ package.json | 11 ++++++----- 3 files changed, 39 insertions(+), 5 deletions(-) diff --git a/app/layout.tsx b/app/layout.tsx index 3314e47..256bbec 100644 --- a/app/layout.tsx +++ b/app/layout.tsx @@ -1,6 +1,7 @@ import type { Metadata } from "next"; import { Inter } from "next/font/google"; import "./globals.css"; +import PlausibleProvider from "next-plausible"; const inter = Inter({ subsets: ["latin"] }); @@ -16,6 +17,9 @@ export default function RootLayout({ }>) { return ( + + + {children} ); diff --git a/package-lock.json b/package-lock.json index 76849c1..9487176 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,6 +9,7 @@ "version": "0.1.0", "dependencies": { "next": "14.2.0", + "next-plausible": "^3.12.0", "react": "^18", "react-dom": "^18" }, @@ -3150,6 +3151,19 @@ } } }, + "node_modules/next-plausible": { + "version": "3.12.0", + "resolved": "https://registry.npmjs.org/next-plausible/-/next-plausible-3.12.0.tgz", + "integrity": "sha512-SSkEqKQ6PgR8fx3sYfIAT69k2xuCUXO5ngkSS19CjxY97lAoZxsfZpYednxB4zo0mHYv87JzhPynrdBPlCBVHg==", + "funding": { + "url": "https://github.com/4lejandrito/next-plausible?sponsor=1" + }, + "peerDependencies": { + "next": "^11.1.0 || ^12.0.0 || ^13.0.0 || ^14.0.0", + "react": "^16.8.0 || ^17.0.0 || ^18.0.0", + "react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0" + } + }, "node_modules/next/node_modules/postcss": { "version": "8.4.31", "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.31.tgz", @@ -4807,6 +4821,21 @@ "funding": { "url": "https://github.com/sponsors/sindresorhus" } + }, + "node_modules/@next/swc-linux-x64-gnu": { + "version": "14.2.0", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-14.2.0.tgz", + "integrity": "sha512-uYHkuTzX0NM6biKNp7hdKTf+BF0iMV254SxO0B8PgrQkxUBKGmk5ysHKB+FYBfdf9xei/t8OIKlXJs9ckD943A==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } } } } diff --git a/package.json b/package.json index 35f7b28..f1bcccb 100644 --- a/package.json +++ b/package.json @@ -9,18 +9,19 @@ "lint": "next lint" }, "dependencies": { + "next": "14.2.0", + "next-plausible": "^3.12.0", "react": "^18", - "react-dom": "^18", - "next": "14.2.0" + "react-dom": "^18" }, "devDependencies": { - "typescript": "^5", "@types/node": "^20", "@types/react": "^18", "@types/react-dom": "^18", + "eslint": "^8", + "eslint-config-next": "14.2.0", "postcss": "^8", "tailwindcss": "^3.4.1", - "eslint": "^8", - "eslint-config-next": "14.2.0" + "typescript": "^5" } }