Nuxt 3 "generate" results in <font-awesome-icon /> to output whatever follows twice
See original GitHub issueDescribe the bug I am using this component with Nuxt 3 as described here and I’m seeing this weird behaviour. Say I have something like this
<a href="https://example.com"><font-awesome-icon icon="fa-brands fa-twitter" />Example</a>
if I run the dev server, everything is fine, but if I run generate
and serve the output through a static HTTP server, I get “Example” printed twice. If I wrap the text in a tag, I get the tag and text twice (i.e. <span>Example</span><span>Example</span>
). Weirdly enough, though, the generated HTML does not contain the repetition, so I suspect something weird is going on in the browser.
Reproducible test case https://andreafranceschini.org/files/afnuxt.tgz
Expected behavior A clear and concise description of what you expected to happen.
Desktop (please complete the following information):
- Happens on all browsers
Issue Analytics
- State:
- Created a year ago
- Reactions:4
- Comments:8 (1 by maintainers)
Top Results From Across the Web
Why does <font-awesome-icon /> output whatever follows ...
I found a workaround, which is to enclose the icon alone in something else, like a span tag.
Read more >Issues · FortAwesome/vue-fontawesome - GitHub
Contribute to FortAwesome/vue-fontawesome development by creating an ... Nuxt 3 "generate" results in <font-awesome-icon /> to output whatever follows twice.
Read more >Use Vue with... | Font Awesome Docs
Install @fortawesome/fontawesome-svg-core and any icon packages you plan to use. Then install the vue-fontawesome component: npm. # for Nuxt 2 ...
Read more >[Solved]-Why is axios not using the settings in nuxt.config.js?
You need to use axios instance created by nuxt itself. ... does <font-awesome-icon /> output whatever follows twice when using Nuxt v3 static...
Read more >[vue warn]: failed to resolve component: font-awesome-icon
You have to either create your Vue.component before the creation of the Vue ViewModel, ... Using FontAwesome in Nuxt 3 · Discussion #3823...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I found a workaround, which is to enclose the
font-awesome-icon
component in a dummy tag like aspan
, in that case I get no duplication (no visible duplication, at least).I am having the same issue and also gettings alot of logs like this from nuxt server side and also wrapping it doesn’t do any good to me.