1
mirror of https://github.com/jakejarvis/jarv.is.git synced 2025-10-23 12:34:29 -04:00

move <Layout> to _app.tsx so it's not rerendered

This commit is contained in:
2022-01-07 09:57:32 -05:00
parent 34d2304e7c
commit 354d767fc5
15 changed files with 388 additions and 328 deletions

View File

@@ -1,7 +1,6 @@
import { MDXRemote } from "next-mdx-remote";
import { serialize } from "next-mdx-remote/serialize";
import { NextSeo, ArticleJsonLd } from "next-seo";
import Layout from "../../components/Layout";
import Content from "../../components/Content";
import Meta from "../../components/notes/Meta";
import mdxComponents from "../../components/mdxComponents";
@@ -53,14 +52,12 @@ const Note = ({ frontMatter, source }) => (
publisherLogo={`${config.baseUrl}/static/images/me.jpg`}
/>
<Layout>
<Meta {...frontMatter} />
<Content>
<div className="markdown">
<MDXRemote {...source} components={mdxComponents} />
</div>
</Content>
</Layout>
<Meta {...frontMatter} />
<Content>
<div className="markdown">
<MDXRemote {...source} components={mdxComponents} />
</div>
</Content>
</>
);