Tell us what’s happening:
Describe your issue in detail here.
**Your code so far**
src="https://www.freecatphotoapp.com/a relaxing cat jpg."
alt="A relaxing cat"
<p>Kitty ipsum dolor sit amet, shed everywhere shed everywhere stretching attack your ankles chase the red dot, hairball run catnip eat the grass sniff.</p>
<p>Purr jump eat the grass rip the couch scratched sunbathe, shed everywhere rip the couch sleep in the sink fluffy fur catnip scratched.</p>
**Your browser information:**
User Agent is:
Mozilla/5.0 (Linux; Android 9; SM-G955F) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.101 Mobile Safari/537.36
Challenge: Add Images to Your Website
Link to the challenge:
The src link is incorrect
<img src="https://www.freecatphotoapp.com/your-image.jpg" alt="A relaxing cat">
Seda is correct. The link to be used is
it’s best not to have linebreaks in the IMG Elements
This is a better format
These URLs don’t end in a period (
I’m not sure if the freeCodeCamp tests will have trouble with linebreaks, but generally speaking, it’s not uncommon to use linebreaks inside of an HTML element if it makes it more readable (typically if the attributes exceed a certain length).
That is Correct. FreeCodeCamp will accept the html even when It look like thie:
You could do it like this, and It could read fine. It would just be considered a really Poor Choice, and your Co-workers will learn to hate you.
Right, it will break on linebreaks inside of strings for URLs though since that is malformed syntax. We see that error often for people working on a mobile device.
Hmm, though not uniformly will it break with linebreaks in URLs it seems. Odd
That would certainly be obnoxious, but breaking long tags along attributes is different. This, for example, is a piece of code from work that I happened to have open in my editor right now:
It is definitely very common with frameworks because components often will end up with a lot of props.
But if you use a code formatter like Prettier which has a maximum line length rule it will also format plain HTML that way.
alt="A relaxing cat"
Thank you very much for your concern
It’s not bad looking
In a way, it’s very tidy and easier to read for possible errors.