refactor: code refactor
This commit is contained in:
parent
45c6fb54a0
commit
b076be8fa7
@ -53,9 +53,11 @@ export default function Index() {
|
|||||||
</a>
|
</a>
|
||||||
</IconContext.Provider>
|
</IconContext.Provider>
|
||||||
</nav>
|
</nav>
|
||||||
<LinkWrapper>
|
<div className="flex justify-center items-center space-x-6">
|
||||||
<Link to="/blog">Blog</Link>
|
<LinkWrapper>
|
||||||
</LinkWrapper>
|
<Link to="/blog">Blog</Link>
|
||||||
|
</LinkWrapper>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -46,7 +46,7 @@ export const meta: MetaFunction<typeof loader> = ({ data }) => {
|
|||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
export default function () {
|
export default function Post() {
|
||||||
const {
|
const {
|
||||||
code,
|
code,
|
||||||
frontmatter: { title, published },
|
frontmatter: { title, published },
|
||||||
@ -62,7 +62,7 @@ export default function () {
|
|||||||
<time>{formattedDate}</time>
|
<time>{formattedDate}</time>
|
||||||
</div>
|
</div>
|
||||||
<div className="flex flex-col items-center">
|
<div className="flex flex-col items-center">
|
||||||
<div className="space-y-5 sm:w-full sm:px-5 lg:w-5/6 xl:w-1/3">
|
<div className="space-y-5 sm:w-full sm:px-5 lg:w-5/6 xl:w-2/3">
|
||||||
<div className="dark:prose-invert prose-a:no-underline prose-a:font-bold hover:prose-a:text-[#ffff00] prose-p:text-[#d6d6d6]">
|
<div className="dark:prose-invert prose-a:no-underline prose-a:font-bold hover:prose-a:text-[#ffff00] prose-p:text-[#d6d6d6]">
|
||||||
<MdxComponent />
|
<MdxComponent />
|
||||||
</div>
|
</div>
|
||||||
|
@ -13,7 +13,7 @@ export const loader = () => {
|
|||||||
return findPosts();
|
return findPosts();
|
||||||
};
|
};
|
||||||
|
|
||||||
export default function () {
|
export default function Blog() {
|
||||||
const posts = useLoaderData<typeof loader>();
|
const posts = useLoaderData<typeof loader>();
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
@ -20,7 +20,7 @@ export const meta: MetaFunction = () => {
|
|||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
export default function () {
|
export default function BlogLayout() {
|
||||||
const { handle } = useMatch();
|
const { handle } = useMatch();
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
Loading…
x
Reference in New Issue
Block a user