Unverified Commit bb973be2 authored by Pavel Mineev's avatar Pavel Mineev Committed by GitHub

fix: move viewport meta tag to head in _app.js (#25901)

Fixes one of the items that was mentioned in  #25854. 
It fixes the warning in `with-next-page-transitions` by moving the viewport tag to `_app.js` from `_document.js`
parent 90c64435
import Head from 'next/head'
import { PageTransition } from 'next-page-transitions' import { PageTransition } from 'next-page-transitions'
import Loader from '../components/Loader' import Loader from '../components/Loader'
...@@ -7,6 +8,9 @@ const TIMEOUT = 400 ...@@ -7,6 +8,9 @@ const TIMEOUT = 400
function MyApp({ Component, pageProps }) { function MyApp({ Component, pageProps }) {
return ( return (
<> <>
<Head>
<meta name="viewport" content="initial-scale=1.0, width=device-width" />
</Head>
<PageTransition <PageTransition
timeout={TIMEOUT} timeout={TIMEOUT}
classNames="page-transition" classNames="page-transition"
......
...@@ -10,10 +10,6 @@ export default class MyDocument extends Document { ...@@ -10,10 +10,6 @@ export default class MyDocument extends Document {
return ( return (
<Html lang="en"> <Html lang="en">
<Head> <Head>
<meta
name="viewport"
content="initial-scale=1.0, width=device-width"
/>
<link <link
rel="stylesheet" rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta.3/css/bootstrap.min.css" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta.3/css/bootstrap.min.css"
......
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