Integrate ads to enhance platform monetization and user engagement

Introduce AdSenseAd component and integrate it across multiple pages (VideoPage, Home) to display various ad formats, including header, sidebar, and mid-content placements.

Replit-Commit-Author: Agent
Replit-Commit-Session-Id: 946a0075-7e32-454b-b348-9e7f576d7f45
Replit-Commit-Checkpoint-Type: full_checkpoint
Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/60d372ff-2c10-46c7-b01b-10c3435136b0/946a0075-7e32-454b-b348-9e7f576d7f45/tiAdL5T
This commit is contained in:
sebastjanartic
2025-09-04 16:24:43 +00:00
parent 8a497293cb
commit dd8ec301e2
3 changed files with 116 additions and 0 deletions
+37
View File
@@ -5,6 +5,7 @@ import NetflixGrid from "@/components/netflix-grid";
import { Link } from "wouter";
import { Input } from "@/components/ui/input";
import { Search, Menu, X } from "lucide-react";
import AdSenseAd from "@/components/adsense-ad";
interface VideosResponse {
videos: Video[];
@@ -194,15 +195,51 @@ export default function Home() {
)}
</div>
{/* Header Banner Ad */}
<div className="container py-4 border-b border-white/10">
<div className="flex justify-center">
<AdSenseAd
adSlot="1234567890"
adFormat="horizontal"
width={728}
height={90}
className="max-w-full"
/>
</div>
</div>
<main className="w-full pt-8 pb-8 relative">
<div className="container">
<NetflixGrid
videos={allVideos}
isLoading={isLoading}
/>
{/* Mid-content Rectangle Ad */}
<div className="flex justify-center my-8 py-4">
<AdSenseAd
adSlot="1234567891"
adFormat="rectangle"
width={336}
height={280}
/>
</div>
</div>
</main>
{/* Bottom Banner Ad */}
<div className="container py-4 border-t border-white/10">
<div className="flex justify-center">
<AdSenseAd
adSlot="1234567892"
adFormat="horizontal"
width={728}
height={90}
className="max-w-full"
/>
</div>
</div>
{/* Footer */}
<footer className="bg-bunny-dark/90 border-t border-white/10 py-8 mt-12">
<div className="container">