Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript JavaScript Objects Loop Through Objects Display an Array of Objects on the Page – One Solution

Stephen Drake
Stephen Drake
784 Points

Picture doesnt show the rest is visible

I was able to almost complete it, just struggling with display pictures.

https://w.trhou.se/4sbrfrf42i

here is the snapshot

1 Answer

Rohald van Merode
seal-mask
STAFF
.a{fill-rule:evenodd;}techdegree
Rohald van Merode
Treehouse Staff

Hey Stephen Drake 👋

You're super close to getting this working! There's only one $ character that sneaked into your template literal at the end of line 24 that needs to be removed:

let img = `${pets[prop]["img"]}$`;

This is causing the src attributes to be set to a path like: img/ausie.jpg$ instead of the regular file extension .jpg. After removing it your images should start showing up as expected! 😃

Hope this help!