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 trialmv t
5,513 PointsGot the correct output, but there is still Bummer showed
Hello guys,
In this challenge, I got the correct output, but still Bummer showed like this:
Bummer! Your double-brackets in the <p> element need to output the user.name property.
Thank you for your help!
<!DOCTYPE html>
<html ng-app="myApp">
<head>
<title>Angular.js</title>
</head>
<body ng-controller="stageTwoControl">
<script src="js/angular.js"></script>
<script src="app.js"></script>
<p>{{ 'Hello ' + user.name }}</p>
</body>
</html>
var myApp = angular.module('myApp',[])
.controller('stageTwoControl', function($scope){
$scope.user = {
name:"sarah",
email:"xx@gmail.com"
};
});
2 Answers
Chris Shaw
26,676 PointsHi mavis yc,
While you may have achieved the correct result outside of the challenge it's not expecting string concatenation, instead it's expecting for you to use Angulars template system to print the property name
in the user
object after the world Hello.
See the below.
<p>Hello {{user.name}}</p>
Happy coding!
mv t
5,513 PointsThank you so much! Chris Upjohn