19 Replies
I'm wondering what is the most compatible elemtns to use for image, and every text
that's an impossible question
"most compatible" is an
<img>
but an svg
´is equally valid as well, and can be better
for the text, it depends on the rest of the page and what you want
there isn't a "this is it" answer for you
hell, if you wanted, you could do this all with an svg
or with a div
or with paragraphsOf course I can, but I want to type it following best pratices as much as I can
well, the "best practices" depend on the rest of the page and your expectations
sorry, I didn't understand how?
well, lets start with the image
do you use any framework?
nope
just plain html, css, js
do you mind doing something a tiny bit hacky, to make it easier to change and reuse the image?
no problem
I don't mind
will you use symbols on your website?
this is not a website. It is a small exercise from front end mentors
then lets simplify it
use an
<img>
with the width
, height
and alt
attributes set
the alt
is mandatoryok that is for image, what about
Report for
and namethat's very tricky, but i would use a
<span>
for the tiny text, and an <h1>
for the nameok, thanks a lot for your help. I'll do it this way
you're welcome