favicon在Next.js 13中不起作用,为什么?

huangapple go评论66阅读模式
英文:

favicon is not working in next js 13 why?

问题

export const metadata = {
  title: "Pradeep's Resume",
  icons: {
    icon: "/icon.png",
  },
};

can anyone tell me why this is not working ? I try doing .ico still not working
I remove Vercel favicon and it is still there
github-link: https://github.com/pradeep800/resume/blob/main/app/layout.tsx
URL:-https://resume.pradeepbisht.com/


<details>
<summary>英文:</summary>

```js
export const metadata = {
  title: &quot;Pradeep&#39;s Resume&quot;,
  icons: {
    icon: &quot;/icon.png&quot;,
  },
};

can anyone tell me why this is not working ? I try doing .ico still not working
I remove Vercel favicon and it is still there
github-link: https://github.com/pradeep800/resume/blob/main/app/layout.tsx
URL:-https://resume.pradeepbisht.com/

答案1

得分: 2

app目录下,你有一个favicon.ico文件。删除它。看起来next.js将其用作默认选项。然后它会起作用:

favicon在Next.js 13中不起作用,为什么?

英文:

in app directory, you have favicon.ico. delete it. looks like next.js using it as the default option. then it works:

favicon在Next.js 13中不起作用,为什么?

huangapple
  • 本文由 发表于 2023年6月2日 10:13:56
  • 转载请务必保留本文链接:https://go.coder-hub.com/76386740.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定