Skip to content

Commit e4cb224

Browse files
Adds tracking codes to Learn links on the home page and nav
WT.mc_id=devproxy-site-{hero,features,quickstart,cta,nav} so Learn analytics shows which part of devproxy.net sends visitors to the docs.
1 parent 0126202 commit e4cb224

2 files changed

Lines changed: 15 additions & 15 deletions

File tree

‎src/layouts/Layout.astro‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ const structuredDataJson = structuredData
126126
<a href={`${import.meta.env.BASE_URL}`} class="hover:text-purple-400 transition-colors" style="color: var(--text-muted);">Home</a>
127127
<a href={`${import.meta.env.BASE_URL}blog/`} class="hover:text-purple-400 transition-colors" style="color: var(--text-muted);">Blog</a>
128128
<a href={`${import.meta.env.BASE_URL}samples/`} class="hover:text-purple-400 transition-colors" style="color: var(--text-muted);">Samples</a>
129-
<a href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/overview" target="_blank" rel="noopener" class="hover:text-purple-400 transition-colors" style="color: var(--text-muted);">Docs ↗</a>
129+
<a href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/overview?WT.mc_id=devproxy-site-nav" target="_blank" rel="noopener" class="hover:text-purple-400 transition-colors" style="color: var(--text-muted);">Docs ↗</a>
130130
<div class="flex items-center gap-3 ml-2 border-l pl-4" style="border-color: var(--border-primary);">
131131
<a href="https://github.com/dotnet/dev-proxy" target="_blank" rel="noopener" class="hover:text-purple-400 transition-colors" style="color: var(--text-muted);" title="GitHub" aria-label="Dev Proxy on GitHub">
132132
<svg class="w-5 h-5" fill="currentColor" viewBox="0 0 24 24" aria-hidden="true">
@@ -194,7 +194,7 @@ const structuredDataJson = structuredData
194194
<a href={`${import.meta.env.BASE_URL}`} class="py-2 hover:text-purple-400 transition-colors" style="color: var(--text-muted);">Home</a>
195195
<a href={`${import.meta.env.BASE_URL}blog/`} class="py-2 hover:text-purple-400 transition-colors" style="color: var(--text-muted);">Blog</a>
196196
<a href={`${import.meta.env.BASE_URL}samples/`} class="py-2 hover:text-purple-400 transition-colors" style="color: var(--text-muted);">Samples</a>
197-
<a href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/overview" target="_blank" rel="noopener" class="py-2 hover:text-purple-400 transition-colors" style="color: var(--text-muted);">Docs ↗</a>
197+
<a href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/overview?WT.mc_id=devproxy-site-nav" target="_blank" rel="noopener" class="py-2 hover:text-purple-400 transition-colors" style="color: var(--text-muted);">Docs ↗</a>
198198
</div>
199199
</div>
200200
</nav>

‎src/pages/index.astro‎

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ const structuredData = {
4848
</p>
4949
<div class="hero-fade hero-fade-4 flex gap-4 justify-center flex-wrap">
5050
<a
51-
href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/get-started"
51+
href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/get-started?WT.mc_id=devproxy-site-hero"
5252
target="_blank"
5353
rel="noopener"
5454
class="group px-8 py-4 bg-purple-600 hover:bg-purple-500 text-white font-semibold rounded-full transition-all duration-300 hover:shadow-[0_0_30px_rgba(168,85,247,0.4)]"
@@ -155,7 +155,7 @@ const structuredData = {
155155
<p class="text-lg leading-relaxed mb-6" style="color: var(--text-muted);">
156156
Stand up a fully-functional CRUD API without writing a single line of server code. Design, prototype, and build your frontend in parallel with your backend.
157157
</p>
158-
<a href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/simulate-crud-api" target="_blank" rel="noopener" class="text-purple-400 hover:text-purple-300 font-medium transition-colors">
158+
<a href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/simulate-crud-api?WT.mc_id=devproxy-site-features" target="_blank" rel="noopener" class="text-purple-400 hover:text-purple-300 font-medium transition-colors">
159159
Learn more &rarr;
160160
</a>
161161
</div>
@@ -179,7 +179,7 @@ const structuredData = {
179179
<p class="text-lg leading-relaxed mb-6" style="color: var(--text-muted);">
180180
Simulate random errors, timeouts, and failures for any API — without touching your code. Build more robust apps and never lose your customers' data.
181181
</p>
182-
<a href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/test-my-app-with-random-errors" target="_blank" rel="noopener" class="text-purple-400 hover:text-purple-300 font-medium transition-colors">
182+
<a href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/test-my-app-with-random-errors?WT.mc_id=devproxy-site-features" target="_blank" rel="noopener" class="text-purple-400 hover:text-purple-300 font-medium transition-colors">
183183
Learn more &rarr;
184184
</a>
185185
</div>
@@ -202,7 +202,7 @@ const structuredData = {
202202
<p class="text-lg leading-relaxed mb-6" style="color: var(--text-muted);">
203203
Route OpenAI and Azure OpenAI API calls to a local language model during development. Get real responses while building your AI-powered apps&thinsp;&mdash;&thinsp;without spending tokens.
204204
</p>
205-
<a href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/simulate-openai" target="_blank" rel="noopener" class="text-purple-400 hover:text-purple-300 font-medium transition-colors">
205+
<a href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/simulate-openai?WT.mc_id=devproxy-site-features" target="_blank" rel="noopener" class="text-purple-400 hover:text-purple-300 font-medium transition-colors">
206206
Learn more &rarr;
207207
</a>
208208
</div>
@@ -224,7 +224,7 @@ const structuredData = {
224224
<p class="text-lg leading-relaxed mb-6" style="color: var(--text-muted);">
225225
Simulate rate limiting and throttling responses before they happen in production. Avoid getting blocked and deliver a smoother experience for your users.
226226
</p>
227-
<a href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/simulate-rate-limit-api-responses" target="_blank" rel="noopener" class="text-purple-400 hover:text-purple-300 font-medium transition-colors">
227+
<a href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/simulate-rate-limit-api-responses?WT.mc_id=devproxy-site-features" target="_blank" rel="noopener" class="text-purple-400 hover:text-purple-300 font-medium transition-colors">
228228
Learn more &rarr;
229229
</a>
230230
</div>
@@ -261,7 +261,7 @@ const structuredData = {
261261
<p class="text-lg leading-relaxed mb-6" style="color: var(--text-muted);">
262262
Run Dev Proxy as part of your CI/CD pipeline to catch API integration issues before they reach production. Works with GitHub Actions, Azure DevOps, and more.
263263
</p>
264-
<a href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/use-dev-proxy-with-github-actions" target="_blank" rel="noopener" class="text-purple-400 hover:text-purple-300 font-medium transition-colors">
264+
<a href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/use-dev-proxy-with-github-actions?WT.mc_id=devproxy-site-features" target="_blank" rel="noopener" class="text-purple-400 hover:text-purple-300 font-medium transition-colors">
265265
Learn more &rarr;
266266
</a>
267267
</div>
@@ -364,12 +364,12 @@ const structuredData = {
364364
</div>
365365
<div class="section-reveal grid md:grid-cols-2 lg:grid-cols-3 gap-6">
366366
{[
367-
{ title: 'Mock an API that doesn\'t exist yet', time: '10 min', href: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/simulate-crud-api' },
368-
{ title: 'Test my app handles API errors', time: '5 min', href: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/test-my-app-with-random-errors' },
369-
{ title: 'Simulate OpenAI with a local LLM', time: '15 min', href: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/simulate-openai' },
370-
{ title: 'Simulate rate limiting responses', time: '10 min', href: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/simulate-rate-limit-api-responses' },
371-
{ title: 'Automate API testing in CI/CD', time: '15 min', href: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/use-dev-proxy-with-github-actions' },
372-
{ title: 'Discover what APIs my app calls', time: '5 min', href: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/discover-urls-to-watch' },
367+
{ title: 'Mock an API that doesn\'t exist yet', time: '10 min', href: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/simulate-crud-api?WT.mc_id=devproxy-site-quickstart' },
368+
{ title: 'Test my app handles API errors', time: '5 min', href: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/test-my-app-with-random-errors?WT.mc_id=devproxy-site-quickstart' },
369+
{ title: 'Simulate OpenAI with a local LLM', time: '15 min', href: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/simulate-openai?WT.mc_id=devproxy-site-quickstart' },
370+
{ title: 'Simulate rate limiting responses', time: '10 min', href: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/simulate-rate-limit-api-responses?WT.mc_id=devproxy-site-quickstart' },
371+
{ title: 'Automate API testing in CI/CD', time: '15 min', href: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/use-dev-proxy-with-github-actions?WT.mc_id=devproxy-site-quickstart' },
372+
{ title: 'Discover what APIs my app calls', time: '5 min', href: 'https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/how-to/discover-urls-to-watch?WT.mc_id=devproxy-site-quickstart' },
373373
].map((scenario) => (
374374
<a
375375
href={scenario.href}
@@ -476,7 +476,7 @@ const structuredData = {
476476
</p>
477477
<div class="section-reveal flex gap-4 justify-center flex-wrap">
478478
<a
479-
href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/get-started"
479+
href="https://learn.microsoft.com/microsoft-cloud/dev/dev-proxy/get-started?WT.mc_id=devproxy-site-cta"
480480
target="_blank"
481481
rel="noopener"
482482
class="group px-8 py-4 bg-purple-600 hover:bg-purple-500 text-white font-semibold rounded-full transition-all duration-300 hover:shadow-[0_0_30px_rgba(168,85,247,0.4)]"

0 commit comments

Comments
 (0)