@Trying_to_learn because things aren’t confusing enough yet... the code you have is good and works for version 4.7 of Font Awesome. The code in the link you found is also good, but needs version 5+ of Font Awesome, which was released about 2 years ago. Font Awesome 5 introduced several base fonts with different styling, for example to allow Bold and Italic. It’s been almost 14 months ago that I last used version 5 in a project, but I believe the fas is now standing for “font awesome standard (font)”, to differentiate between the sets of fonts.
In practice however, none of this matters as the Dashboard only supports version 4.7 style font awesome icons. But thankfully the site I always used as cheatsheet for 4.7 still exists: https://fontawesome.bootstrapcheatsheets.com/
That page shows the icon with the CSS class for all options you have for the Dashboard when using font-awesome.
One more thing to add in a new post rather than edit the previous one: as I just learned FA 4.7 does also allow some animations, specifically for the spinner too. I’m on mobile so I haven’t tested this in Node-RED yet but the following should work:
<i class="fa fa-spinner fa-spin"></i>
These classes mean the following:
fa to signal that a font awesome icon is coming,
fa-spinner for the spinner icon (see link in the previous post),
fa-spin to set it to animate fluently
See the examples on this page that’s hard to find as they want everyone to use version 5 (because some parts of v5 are paid) instead. https://fontawesome.com/v4.7.0/examples/
Specifically the part on animated icons but I can’t find an anchor to link it directly
Coming from that developer experience with font-awesome 5, I’m not sure if it’s worth the trouble to get that working in the dashboard. FA5 wants you to use it internally in your JavaScript code mostly, and elsewhere in your project. You’ve to jump through hoops to use it elsewhere. I used it in combination with Vue and it took me a day to figure out how to use it. I’m back to font awesome 4.7 now
What could be improved is the documentation and finding information on the old FA 4.7 docs for the Dashboard, I’ll see if I can improve a few things there sometime