Skip to content

Commit 6b12e0a

Browse files
authored
chore(web): Rename Examples to Templates (#1666)
1 parent 85af3b3 commit 6b12e0a

File tree

4 files changed

+13
-8
lines changed

4 files changed

+13
-8
lines changed

apps/web/next.config.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@ module.exports = {
1313
destination: "https://discord.com/invite/n2pWEjjNnD",
1414
permanent: true,
1515
},
16+
{
17+
source: "/examples",
18+
destination: "/templates",
19+
permanent: true,
20+
},
1621
];
1722
},
1823
async rewrites() {

apps/web/src/app/examples/page.tsx renamed to apps/web/src/app/templates/page.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import type { Metadata } from "next";
22
import Image from "next/image";
33
import { Anchor } from "../../components/anchor";
4-
import { Example } from "../../components/example";
4+
import { Template } from "../../components/template";
55
import { Heading } from "../../components/heading";
66
import { Text } from "../../components/text";
77
import PageTransition from "../../components/page-transition";
@@ -104,7 +104,7 @@ const items = [
104104
},
105105
];
106106

107-
const title = "Examples — React Email";
107+
const title = "Templates — React Email";
108108
const description = "Open source templates built with React Email";
109109
export const metadata: Metadata = {
110110
title,
@@ -115,7 +115,7 @@ export const metadata: Metadata = {
115115
},
116116
};
117117

118-
const Examples = () => (
118+
const Templates = () => (
119119
<>
120120
<Image
121121
alt=""
@@ -131,7 +131,7 @@ const Examples = () => (
131131
>
132132
<div className="mb-12 text-pretty px-6 md:max-w-[46rem] md:px-0 md:text-center">
133133
<Heading className="text-white" size="6">
134-
Examples
134+
Templates
135135
</Heading>
136136
<Text as="p" className="mt-4 text-slate-11" size="2">
137137
{description}.
@@ -156,11 +156,11 @@ const Examples = () => (
156156
</div>
157157
<div className="grid grid-cols-1 gap-8 md:grid-cols-2">
158158
{items.map((item) => (
159-
<Example key={item.path} {...item} />
159+
<Template key={item.path} {...item} />
160160
))}
161161
</div>
162162
</PageTransition>
163163
</>
164164
);
165165

166-
export default Examples;
166+
export default Templates;

apps/web/src/components/menu.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ const MenuItems = ({ onItemClick }: { onItemClick: () => void }) => (
5151
href="/examples"
5252
onClick={onItemClick}
5353
>
54-
Examples
54+
Templates
5555
</MenuItem>
5656
<MenuItem
5757
className="w-full px-2 md:w-fit"

apps/web/src/components/example.tsx renamed to apps/web/src/components/template.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ const imageLoader: ImageLoader = ({ src, width, quality }) => {
2222
return `${src}?w=${width}&q=${quality || 75}`;
2323
};
2424

25-
export const Example: React.FC<Readonly<ExampleProps>> = ({
25+
export const Template: React.FC<Readonly<ExampleProps>> = ({
2626
className,
2727
path,
2828
name,

0 commit comments

Comments
 (0)