Skip to content

Commit 1681317

Browse files
committed
feat: add SEO metadata and branding assets
1 parent e58e5fa commit 1681317

File tree

5 files changed

+55
-81
lines changed

5 files changed

+55
-81
lines changed

apps/collabydraw/app/layout.tsx

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ import Provider from "./provider";
55
import { Toaster } from "sonner";
66
import { ThemeProvider } from "@/components/theme-provider";
77
import { baseMetadata, jsonLdSchema } from "@/utils/metadata";
8+
import Script from "next/script";
9+
import { Analytics } from "@vercel/analytics/react"
810

911
const geistSans = Geist({
1012
variable: "--font-geist-sans",
@@ -37,6 +39,22 @@ export default function RootLayout({
3739
return (
3840
<html lang="en">
3941
<head>
42+
<Script
43+
strategy="afterInteractive"
44+
src="https://www.googletagmanager.com/gtag/js?id=G-85S7XMW3W2"
45+
/>
46+
<Script
47+
id="google-analytics"
48+
strategy="afterInteractive"
49+
dangerouslySetInnerHTML={{
50+
__html: `
51+
window.dataLayer = window.dataLayer || [];
52+
function gtag(){dataLayer.push(arguments);}
53+
gtag('js', new Date());
54+
gtag('config', 'G-85S7XMW3W2');
55+
`,
56+
}}
57+
/>
4058
<script
4159
type="application/ld+json"
4260
dangerouslySetInnerHTML={{
@@ -53,6 +71,7 @@ export default function RootLayout({
5371
</ThemeProvider>
5472
<Toaster />
5573
</Provider>
74+
<Analytics/>
5675
</body>
5776
</html>
5877
);

apps/collabydraw/canvas-engine/CanvasEngine.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,7 @@ export class CanvasEngine {
141141
if (!this.isStandalone && this.token && this.roomId) {
142142
console.log("✅Connecting to WebSocket…");
143143
this.connectWebSocket();
144+
console.log("✅Connected to WebSocket…");
144145
}
145146
}
146147

@@ -1047,9 +1048,6 @@ export class CanvasEngine {
10471048
textarea.style.width = `${Math.max(span!.offsetWidth + 10, 50)}px`;
10481049
textarea.style.height = `${Math.max(span!.offsetHeight, 20)}px`;
10491050
});
1050-
1051-
console.log("span.offsetWidth= ", span.offsetWidth);
1052-
console.log("textarea.style.width= ", textarea.style.width);
10531051
};
10541052

10551053
textarea.addEventListener("input", () => {

apps/collabydraw/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
"@radix-ui/react-separator": "^1.1.2",
2222
"@radix-ui/react-slot": "^1.1.2",
2323
"@radix-ui/react-tooltip": "^1.1.8",
24+
"@vercel/analytics": "^1.5.0",
2425
"axios": "^1.7.9",
2526
"bcrypt": "^5.1.1",
2627
"class-variance-authority": "^0.7.1",

apps/collabydraw/test/test.html

Lines changed: 0 additions & 78 deletions
This file was deleted.

pnpm-lock.yaml

Lines changed: 34 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)