Skip to content

Commit 441f93e

Browse files
authored
Merge branch 'main' into fix/landingpage-product-section
2 parents 5529e7d + 6c8a433 commit 441f93e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+751
-127
lines changed

docusaurus.config.js

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,36 @@ module.exports = {
7979
logo: "https://keploy.io/docs/img/favicon.png",
8080
}),
8181
},
82+
{
83+
tagName: "script",
84+
attributes: {
85+
type: "application/ld+json",
86+
},
87+
innerHTML: JSON.stringify({
88+
"@context": "https://schema.org/",
89+
"@type": "Organization",
90+
name: "Keploy",
91+
url: "https://keploy.io/",
92+
logo: "https://keploy.io/docs/img/favicon.png",
93+
}),
94+
},
95+
{
96+
tagName: "script",
97+
attributes: {
98+
type: "application/ld+json",
99+
},
100+
innerHTML: JSON.stringify({
101+
"@context": "https://schema.org/",
102+
"@type": "WebSite",
103+
name: "Keploy Documentation",
104+
url: "https://keploy.io/docs/",
105+
potentialAction: {
106+
"@type": "SearchAction",
107+
target: "https://keploy.io/docs/search?q={search_term_string}",
108+
"query-input": "required name=search_term_string",
109+
},
110+
}),
111+
},
82112
],
83113
colorMode: {
84114
defaultMode: "light",

src/components/ProductTier.js

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
import React from "react";
2+
3+
const ProductTier = ({tiers, offerings}) => {
4+
return (
5+
<div className="my-4 rounded-lg border border-gray-300 bg-[#fff8f5] p-4 text-gray-900 shadow-sm dark:border-gray-700 dark:bg-[#23272f] dark:text-gray-100">
6+
<div className="flex flex-col gap-2">
7+
{tiers && (
8+
<div className="flex flex-wrap items-center gap-2">
9+
<span className="font-bold">Tier:</span>
10+
<span>{Array.isArray(tiers) ? tiers.join(", ") : tiers}</span>
11+
</div>
12+
)}
13+
{offerings && (
14+
<div className="flex flex-wrap items-center gap-2">
15+
<span className="font-bold">Offering:</span>
16+
<span>
17+
{Array.isArray(offerings) ? offerings.join(", ") : offerings}
18+
</span>
19+
</div>
20+
)}
21+
</div>
22+
</div>
23+
);
24+
};
25+
26+
export default ProductTier;

src/components/QuickStartList.js

Lines changed: 19 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ const quickstarts = [
100100
},
101101
*/
102102

103-
/*{
103+
{
104104
title: "Gin + Redis",
105105
language: "Go",
106106
server: "Docker",
@@ -116,7 +116,6 @@ const quickstarts = [
116116
"A sample User Authentication app to demonstrate how seamlessly Keploy integrates with Gin and Redis.",
117117
link: "/docs/quickstart/samples-redis/#running-app-locally-on-linuxwsl-",
118118
},
119-
*/
120119
{
121120
title: "Mux + Postgres",
122121
language: "Go",
@@ -204,15 +203,14 @@ const quickstarts = [
204203

205204
// python list
206205

207-
/*{
206+
{
208207
title: "E-commerce Microservices",
209208
language: "Python",
210209
server: "Docker",
211210
description:
212211
"This guide walks you through testing an E-commerce microservices application using Keploy.",
213212
link: "/docs/quickstart/samples-microservices/",
214213
},
215-
*/
216214
{
217215
title: "Django + Postgres",
218216
language: "Python",
@@ -281,6 +279,15 @@ const quickstarts = [
281279
link: "/docs/quickstart/samples-fastapi-twilio/#using-docker-compose-",
282280
},
283281

282+
{
283+
title: "Python + K8s",
284+
language: "Python",
285+
server: "Docker",
286+
description:
287+
"A sample guide demonstrating how to perform live traffic recording and replay in a Kubernetes environment.",
288+
link: "/docs/quickstart/k8s-proxy/",
289+
},
290+
284291
/*{
285292
title: "Sanic + Mongo",
286293
language: "Python",
@@ -290,15 +297,14 @@ const quickstarts = [
290297
link: "/docs/quickstart/sanic-mongo/",
291298
},
292299
*/
293-
/*{
294-
title: "Flask + Redis",
295-
language: "Python",
296-
server: "Docker",
297-
description:
298-
"A sample Student CRUD app to demonstrate how seamlessly Keploy integrates with Flask and Redis.",
299-
link: "/docs/quickstart/flask-redis/",
300-
},
301-
*/
300+
{
301+
title: "Flask + Redis",
302+
language: "Python",
303+
server: "Docker",
304+
description:
305+
"A sample Student CRUD app to demonstrate how seamlessly Keploy integrates with Flask and Redis.",
306+
link: "/docs/quickstart/flask-redis/",
307+
},
302308

303309
//Javascript list
304310

src/pages/index.js

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,81 @@
11
import React from "react";
22
import Layout from "@theme/Layout";
3+
import Head from "@docusaurus/Head";
34
import useDocusaurusContext from "@docusaurus/useDocusaurusContext";
45
import {Community, KeployCloud, Resources, QuickStart} from "../components";
56
import {Products} from "../components/Product";
67
//import {Intro} from "../components";
78
export default function Home() {
89
const context = useDocusaurusContext();
910
const {siteConfig = {}} = context;
11+
const toAbsoluteUrl = (baseUrl, url) => {
12+
if (!url) {
13+
return null;
14+
}
15+
if (url.startsWith("http://") || url.startsWith("https://")) {
16+
return url;
17+
}
18+
const trimmedBase = baseUrl?.replace(/\/$/, "") ?? "";
19+
const normalizedPath = url.startsWith("/") ? url : `/${url}`;
20+
return `${trimmedBase}${normalizedPath}`;
21+
};
22+
const docsUrl = toAbsoluteUrl(siteConfig.url, siteConfig.baseUrl);
23+
const breadcrumbSchema =
24+
docsUrl && siteConfig.url
25+
? {
26+
"@context": "https://schema.org",
27+
"@type": "BreadcrumbList",
28+
itemListElement: [
29+
{
30+
"@type": "ListItem",
31+
position: 1,
32+
name: "Home",
33+
item: siteConfig.url,
34+
},
35+
{
36+
"@type": "ListItem",
37+
position: 2,
38+
name: "Docs",
39+
item: docsUrl,
40+
},
41+
],
42+
}
43+
: null;
44+
const articleSchema =
45+
docsUrl && siteConfig.title
46+
? {
47+
"@context": "https://schema.org",
48+
"@type": "Article",
49+
headline: siteConfig.title,
50+
description: siteConfig.tagline,
51+
mainEntityOfPage: {
52+
"@type": "WebPage",
53+
"@id": docsUrl,
54+
},
55+
publisher: {
56+
"@type": "Organization",
57+
name: "Keploy",
58+
logo: {
59+
"@type": "ImageObject",
60+
url: "https://keploy.io/docs/img/favicon.png",
61+
},
62+
},
63+
}
64+
: null;
1065
return (
1166
<div className="main">
67+
<Head>
68+
{breadcrumbSchema && (
69+
<script type="application/ld+json">
70+
{JSON.stringify(breadcrumbSchema)}
71+
</script>
72+
)}
73+
{articleSchema && (
74+
<script type="application/ld+json">
75+
{JSON.stringify(articleSchema)}
76+
</script>
77+
)}
78+
</Head>
1279
<Layout
1380
className="mx-auto my-2 w-full max-w-screen-lg px-8 shadow-none"
1481
title={`${siteConfig.title}`}

0 commit comments

Comments
 (0)