18 Replies
how are you including font-awesome?
it's a paid icon
my bad, it indeed is a paid icon .
Any recommended sites that is similar to font awesome?
where can i find cdn or similar link to link it to html?
That's not quite how icones works, you can download them as SVGs either individually or by selecting multiple and clicking the basket in the bottom right corner to download them as a zip of svgs or an iconfont
there's lots of options when you click an icon:
understood, if i use SVG path it becomes like a mess, is there a way to avoid this?
i saw somewhere you can create a new file for svg icons, then import it to html . im not sure how it works but i read it somewhere
you can save them as svg files and reference them using an img tag, though it has some drawbacks: https://developer.mozilla.org/en-US/docs/Learn/HTML/Multimedia_and_embedding/Adding_vector_graphics_to_the_Web
so what would you recommend? download svg file or paste the entire path into HTML?
the URL button will also copy the URL for the icon to your clipboard, the DataURL would work with the
url()
function in CSS for the background-image attribute: https://developer.mozilla.org/en-US/docs/Web/CSS/url
that's up to you. I'd put the icon in a svelte component and include it like that, but in vanilla HTML? I'd probably go with the dataurl option in my previous message, and put it in either a separate CSS file, or just in side my main one depending on where they're used and how many icons I havesomething like this?? cause its not showing
are you including the css file? and is the button big enough to show the background?
I believe you're referring to what Kevin did in this video. Starting at 6:15
https://youtu.be/eX9JhQtMxCg
Kevin Powell
YouTube
Build a responsive website with HTML & CSS | Part seven: the footer
In this one, we look at setting up the footer, including creating some SVG sprites for our social icons and using CSS grid for the layout.
🔗 Links
✅ GitHub repo for where I start this video: https://github.com/kevin-powell/fem-manage-landing-page-part-6
✅ The playlist of this series: https://youtube.com/playlist?list=PL4-IK0AVhVjNDRHoXGort7...
yeah its big enough. i kept same css styling and replaced svg in html to new css where i set background:url(dataURL)
did you add a link tag for the new CSS file?
yes
then I don't know what's wrong, it's hard to tell without seeing something more than screenshots