如何更改搜索结果中的“created using create-react-app”?

我试图将我的投资组合的链接发布到 linkedin 上,它总是显示“使用 React 应用程序创建的网站”作为描述,这绝对不会让它看起来很专业。它部署在我的域上,但有什么方法可以摆脱我域链接上的所有 create-react-app 默认内容吗?



凤凰求蛊
浏览 76回答 3
3回答

守着星空守着你

更改 public 文件夹中 index.html 文件的描述和标题,然后重建您的应用&nbsp; <head><meta charset="utf-8" /><link rel="icon" href="%PUBLIC_URL%/favicon.ico" /><meta name="viewport" content="width=device-width, initial-scale=1" /><meta name="theme-color" content="#000000" /><meta&nbsp; name="description"&nbsp; content="Web site created using create-react-app"/><link href="https://fonts.googleapis.com/css?family=Muli:300,400,600,700" rel="stylesheet"><title>React App</title>

一只名叫tom的猫

您需要将这些元标记添加到您的 index.html 的标题中,图像大小也应至少为 1200x627(根据 linkedin文档)<head>&nbsp; &nbsp; <meta property="og:title" content="*TITLE*" />&nbsp; &nbsp; <meta property="og:image" content="%PUBLIC_URL%/linkedin.png" />&nbsp; &nbsp; <meta property="og:description" content="*DESCRIPTION*" /></head>如果您在 LinkedIn 识别新标头时仍然遇到问题,请再次插入 url,但在 url 末尾使用随机参数。因此,如果您的网站网址是: https:&nbsp;//www.example.com尝试使用空参数再次添加链接:&nbsp;https ://www.example.com?1这应该会强制 linkedin 提取新的头部数据。

ITMISS

您需要更改公用文件夹中的 index.htm 文件,标题和元标记将包含此默认标题。
打开App,查看更多内容
随时随地看视频慕课网APP

相关分类

JavaScript