Unverified Commit 29919976 authored by Pavel Ševčík's avatar Pavel Ševčík
Browse files

Move Layout to _app.tsx

parent e24e1134
import React from "react";
import Head from "next/head";
import { Layout } from "../components/Layout";
import "../css/materialize.css";
import "../css/defaults.css";
import "../css/style.css";
......@@ -10,7 +12,7 @@ const description =
const MyApp = ({ Component, pageProps }) => {
return (
<>
<Layout>
<Head>
<meta charSet="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
......@@ -46,7 +48,7 @@ const MyApp = ({ Component, pageProps }) => {
<link rel="manifest" href="/assets/site.webmanifest" />
</Head>
<Component {...pageProps} />
</>
</Layout>
);
};
......
import React from "react";
import Document, { Html, Head, Main, NextScript } from "next/document";
import { Layout } from "../components/Layout";
class MyDocument extends Document {
static async getInitialProps(ctx) {
......@@ -13,9 +12,7 @@ class MyDocument extends Document {
<Html lang="en">
<Head />
<body>
<Layout>
<Main />
</Layout>
<Main />
<NextScript />
</body>
</Html>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment