Hi,

Are you also new to Javascript? 
Apparently I didn't read the entire code well enough ;)

addItems() {
 let newItem = prompt("Enter a new item");
 this.items.push(newItem);
 } 

You really should read up 
<https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/var>
 
on how to declare 
<https://developer.mozilla.org/nl/docs/Web/JavaScript/Reference/Statements/let> 
and use variables and where this 
<https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/this>
 
is about in classes 
<https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Classes>
. 

Regards
Sander

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to