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 trialJa'Quan Thompson
Front End Web Development Techdegree Graduate 15,834 PointsIt asks me to post `:$` immediately after type but Im doing that and it doesnt work
It asks me to post :$
immediately after type but Im doing that and it doesnt work. Does anyone know what I am doing?
const flavor = "Blueberry";
const type = "Smoothie";
const price = 4.99;
const drink = `${flavor} '' ${type}:$ ${price}`;
1 Answer
Michael Cook
Full Stack JavaScript Techdegree Graduate 28,975 PointsHey Ja'Quan, don't worry about it this is simple, but the feedback from the challenge is a bit confusing. Here's the answer:
const flavor = "Blueberry";
const type = "Smoothie";
const price = 4.99;
const drink = `${flavor} ${type}: $${price}`;
If you want to add a $
character infront of an interpolated value, put it right infront of the $
that is used for the interpolation and it will render. The other issue was that you had some empty single quotes that was preventing you from passing the challenge.
Ja'Quan Thompson
Front End Web Development Techdegree Graduate 15,834 PointsJa'Quan Thompson
Front End Web Development Techdegree Graduate 15,834 PointsThank you! This was a tricky one for me but I appreciate you!