In AngularJS , under “Learn”, Instructions part 2 , page 2/11 :
" 2. Likewise, any new properties attached to $scope will become available to use in the view. In the controller, attach promo to $scope, and set its value to your own string. "
When I clicked “run”, it gives the error message :
Did you add $scope.promo to the controller?
Where exactly do I type ? If someone can show me the exact syntax and how it should be written , appreciate it …
I am having a similar issue.
$scope.title = 'Todd is cool!'; $scope.promo = 'This is a promo!';
Why can’t we use any other names???
Also the error occurs if am trying to add another property.
you can add another property in same way as earlier
$scope.hello=‘m another property’;
This AngularJS course isn’t written well at all.
In the controller, attach promo to $scope, and set its value to your own string.
It should probably say, “In MainController.js, type…”
It’s too bad I don’t understand the rest of the instructions, else I could translate it into simpler English.