feat: trim integration pages from 75 to 25 + migrate to MDX
- Add dedicatedPage flag to integration registry (25 true, 50 false) - Delete hardcoded nextjs/react/vue/wordpress route pages (wrong metadata) - Hub page routes non-dedicated integrations to /integrations/script-tag - Add 301 redirects for 50 removed slugs → /integrations/script-tag - Migrate guide content from TSX to MDX (content/integrations/*.mdx) - Add gray-matter, next-mdx-remote, remark-gfm dependencies - Add content loader (lib/integration-content.ts) matching ciphera-website pattern - Add prebuild script for integration guide index generation - Sitemap reduced from 83 to 35 URLs with real lastmod dates - Remove seoDescription from registry (now in MDX frontmatter)
This commit is contained in:
48
content/integrations/astro.mdx
Normal file
48
content/integrations/astro.mdx
Normal file
@@ -0,0 +1,48 @@
|
||||
---
|
||||
title: "Astro"
|
||||
description: "Integrate Pulse analytics with Astro. Add the script to your base layout for all pages."
|
||||
category: "framework"
|
||||
brandColor: "#BC52EE"
|
||||
officialUrl: "https://docs.astro.build"
|
||||
relatedIds: ["svelte", "hugo", "eleventy"]
|
||||
date: "2026-03-28"
|
||||
---
|
||||
|
||||
Add the Pulse script to your base layout so it's included on every page of your Astro site.
|
||||
|
||||
---
|
||||
|
||||
## Add to your base layout
|
||||
|
||||
Place the Pulse script in the `<head>` of your shared layout component.
|
||||
|
||||
<CodeBlock filename="src/layouts/BaseLayout.astro">{`---
|
||||
interface Props {
|
||||
title: string
|
||||
}
|
||||
|
||||
const { title } = Astro.props
|
||||
---
|
||||
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
|
||||
<script
|
||||
defer
|
||||
data-domain="your-site.com"
|
||||
src="https://pulse.ciphera.net/script.js"
|
||||
></script>
|
||||
|
||||
<title>{title}</title>
|
||||
</head>
|
||||
<body>
|
||||
<slot />
|
||||
</body>
|
||||
</html>`}</CodeBlock>
|
||||
|
||||
If you're using Astro's View Transitions, the script will persist across navigations by default since it's in the `<head>`.
|
||||
|
||||
For more details, see the [Astro scripts docs](https://docs.astro.build/en/guides/client-side-scripts/).
|
||||
Reference in New Issue
Block a user