Skip to content

Commit

Permalink
RFix next _document.js according to mui/material-ui#20463
Browse files Browse the repository at this point in the history
Signed-off-by: Janus Reith <mail@janusreith.de>
  • Loading branch information
Janus Reith authored and Janus Reith committed May 19, 2020
1 parent bbe4bb1 commit 84f3610
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions pages/_document.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React, { Fragment } from "react";
import Document, { Head, Main, NextScript } from "next/document";
import Document, { Html, Head, Main, NextScript } from "next/document";
import { ServerStyleSheet as StyledComponentSheets } from "styled-components";
import { ServerStyleSheets as MaterialUiServerStyleSheets } from "@material-ui/styles";
import favicons from "custom/favicons";
Expand Down Expand Up @@ -44,7 +44,7 @@ class HTMLDocument extends Document {
];

return (
<html lang="en">
<Html lang="en">
<Head>
{meta.map((tag, index) => <meta key={index} {...tag} />)}
{links.map((link, index) => <link key={index} {...link} />)}
Expand All @@ -53,9 +53,9 @@ class HTMLDocument extends Document {
<Main />
<NextScript />
{scripts.map((script, index) => (script.innerHTML ? /* eslint-disable-next-line */
<script async key={index} type={script.type} dangerouslySetInnerHTML={{ __html: script.innerHTML }} /> : <script async key={index} {...script} />))}
<script async key={index} type={script.type} dangerouslySetInnerHTML={{ __html: script.innerHTML }} /> : <script async key={index} {...script} />))}
</body>
</html>
</Html>
);
}
}
Expand Down

0 comments on commit 84f3610

Please sign in to comment.