Skip to content

Commit e215a8a

Browse files
remove the unused code.
1 parent c43e388 commit e215a8a

File tree

1 file changed

+7
-19
lines changed

1 file changed

+7
-19
lines changed

app/read/[slug]/page.tsx

Lines changed: 7 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
import { format } from "date-fns";
22
import { ChevronLeft, FileText, Home, Lightbulb, Tag } from "lucide-react";
3-
import { Alert, AlertDescription, AlertTitle } from "@/components/ui/alert";
43
import { Avatar, AvatarFallback, AvatarImage } from "@/components/ui/avatar";
5-
import { GetAllPosts, GetPost, RelatedPosts } from "@/data";
4+
import { GetAllPosts, GetPost } from "@/data";
65
import { notFound } from "next/navigation";
76
import { Button } from "@/components/ui/button";
87
import Link from "next/link";
@@ -27,14 +26,11 @@ export async function generateMetadata({
2726
params: Promise<{ slug: string }>;
2827
}): Promise<Metadata> {
2928
const slug = (await params).slug;
30-
3129
const post = GetPost(slug);
32-
3330
if (!post) {
3431
notFound();
3532
}
36-
37-
return { title: post.title };
33+
return { title: `${post.title} | Blogify` };
3834
}
3935
export default async function Page({
4036
params,
@@ -45,9 +41,11 @@ export default async function Page({
4541
const post = GetPost(slug);
4642

4743
let GetDate = dayjs(post?.date).format("DD MMM, YYYY");
44+
4845
if (post === undefined) {
4946
notFound();
5047
}
48+
5149
return (
5250
<section className="mx-auto flex flex-col">
5351
<div className="container mt-24">
@@ -162,11 +160,7 @@ export default async function Page({
162160
aliquip cillum enim do officia minim labore pariatur nisi irure sunt
163161
anim ullamco.
164162
</p>
165-
<h2>
166-
{" "}
167-
<a id="What_is_Lorem_Ipsum__Meaning_18"></a>What is Lorem Ipsum
168-
Meaning ?
169-
</h2>
163+
<h2> What is Lorem Ipsum Meaning ?</h2>
170164
<p>
171165
Sint qui enim non Lorem aliquip nulla sint. Aute laborum tempor
172166
adipisicing officia magna fugiat sint cupidatat. Enim Lorem officia
@@ -197,10 +191,7 @@ export default async function Page({
197191
nostrud ullamco occaecat nostrud sunt aliquip Lorem fugiat nisi anim
198192
et sunt dolor.
199193
</p>
200-
<h2>
201-
{" "}
202-
<a id="Voluptate_tempor_28"></a>Voluptate tempor
203-
</h2>
194+
<h2> Voluptate tempor</h2>
204195
<p>
205196
Nisi ad aliquip minim quis cupidatat eu minim voluptate tempor
206197
consequat irure eu. Consectetur laboris est ut officia deserunt in
@@ -212,10 +203,7 @@ export default async function Page({
212203
<li>Lorem eiusmod proident</li>
213204
<li>Sunt sit voluptate</li>
214205
</ul>
215-
<h2>
216-
{" "}
217-
<a id="Conclusion_36"></a>Conclusion
218-
</h2>
206+
<h2> Conclusion</h2>
219207
<p>
220208
Consectetur aliqua eu veniam consequat eu adipisicing id ullamco
221209
incididunt. Laboris deserunt labore nisi occaecat amet minim

0 commit comments

Comments
 (0)