我在将移动元标记添加到nextJS应用程序时遇到问题。根据这里的文档,这应该工作https://nextjs.org/docs#populating-head 但是我看不到标题或我自己的任何meta属性都被渲染。我所看到的是: <!DOCTYPE html><html><head><meta charSet="utf-8" class="next-head"/> 看起来像某种默认类型。 import Link from 'next/link' import Head from 'next/head' import Header from '../components/Header' import BaseLayout from '../components/BaseLayout.js' const Index = () => ( <BaseLayout> <Head> <title>HSK App</title> <meta name="viewport" content="initial-scale=1.0, width=device-width" /> </Head> <Link href='/quizList'> <h3>HSK Quiz App!</h3> </Link> </BaseLayout> ) export default Index 感谢帮助! 我在将移动元标记添加到nextJS应用程序时遇到问题。根据这里的文档,这应该可以工作https://nextjs.org/docs#populating-head但我看不到标题或我自己的任何元数据...

问题描述 投票:1回答:1

我在将移动元标记添加到nextJS应用程序时遇到问题。根据这里的文档,这应该工作https://nextjs.org/docs#populating-head

meta next.js html-head
1个回答
0
投票

NextJS的<Head>组件似乎有点问题。

最新问题
© www.soinside.com 2019 - 2025. All rights reserved.