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 Foundations Objects Call and Apply

Need more reference materials on the uses of "this" and Call & Reply Methods

The Objects Challenge task 1 of 1 asks Set the 'greeting' variable, on line 29, by using the 'genericGreet' function in the context of 'andrew' with the array of arguments, 'args1'.

I worked through the question and answered it correctly. I'm happy about that, but I feel like I need more instruction or reference materials on how to effectively use "this" and the Call & Reply methods. I sense these topics are very important in JavaScript programing, and that I will need to fully understand them later. Therefore, I want to make sure I fully get this stuff. Yes, I got the anwer to the challenge question right, but can someone direct me to a really good outside resource about how to use "this" and the call and reply methods. I'm looking for something that breaks it all down as simply as possible. Thanks!

I'm really enjoying learning how to program in JavaScript ... it's new to me, but I find it really interesting .. sort of like a puzzle. That's how I relate to it anyway.

1 Answer

Aaron Graham
Aaron Graham
18,033 Points

I would start here: MDN: this Read through it a couple of times and see if it starts to make sense. It can be a rather confusing matter. Try building some of the examples and experiment a bit. Change some things and try to predict what will happen. That usually helps me. When your predictions are right more than they are wrong, you know you are starting to get it. Also, if you are really interested in learning javascript, I usually recommend Douglas Crockford's book JavaScript: The Good Parts as a good place to start. It gets a little deep at times, but it's a great overview of the language and how best to use it. I have read it several times and still find new things from time to time. Hope that helps you out!

Aaron. Thank you very much for the two references. I'll bookmark the MDS site and spend some time exploring it. I'll also look for Crockford's JavaScript book. I feel like I'm getting the concepts, but I need lots of practice with code before it really clicks for me. The code challenges are great, but as they say, "practice makes perfect (or at least better)." Once again, thanks for the two references and for taking time to help! Best, Ronald