[英]nuxtjs Fontawesome some icons not able to display
Hi I have like to use some fontawesome icons such as Twitter icon.嗨,我喜欢使用一些 fontawesome 图标,例如 Twitter 图标。
In my nuxt.config.js, I have those lines below:在我的 nuxt.config.js 中,我有以下几行:
fontawesome: {
component: "fa",
icons: {
solid: true,
brands: true
}
},
In html, I have these lines below:在 html 中,我有以下几行:
<fa icon="envelope"></fa>
<fa icon="twitter"></fa>
However, the envelop is able to display but not the Twitter icon.但是,信封能够显示但不能显示 Twitter 图标。 Do I miss anything?
我想念什么吗?
The correct way to specify the icons in html should be:在 html 中指定图标的正确方法应该是:
<fa :icon="['fas', 'envelope']" />
<fa :icon="['fas', 'lock']" />
<fa :icon="['fas', 'sign-in-alt']" />
<fa :icon="['fab', 'google']" />
<fa :icon="['fab', 'linkedin']" />
<fa :icon="['fab', 'twitch']" />
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.