Regarding Question 24, I want to really understand "this" so I tested each example in the Console. I found a different result than what you shared for this line...
myFavoriteObj.guessThis();
You wrote that it logs the window object; however, I'm seeing that in normal mode it logs nothing and in strict mode it throws an error. Maybe it is working differently on your browser? I'm using Chrome 81 on Mac.
By the way, I am enjoying studying this post. Thank you!
Regarding Question 24, I want to really understand "this" so I tested each example in the Console. I found a different result than what you shared for this line...
myFavoriteObj.guessThis();
You wrote that it logs the window object; however, I'm seeing that in normal mode it logs nothing and in strict mode it throws an error. Maybe it is working differently on your browser? I'm using Chrome 81 on Mac.
By the way, I am enjoying studying this post. Thank you!
Thanks, for finding my mistake. I edited it just now. No problem man, glad you like it.
Believe it or not, I'm still going through your list and taking notes. This is a very cool post.
By the way, I've cleared my browser cache the graphic is the same. Maybe it's cached on the server side?
I've changed the object.
It looks like this now.
`
Thanks
Ah, I see the change now. You removed
.name
from where it used to sayconsole.log(this.name);
Thank you!Your welcome. Thanks, again for finding my mistake.
Hey , even now i think there is a problem.
Shouldn't it be
this.name = "Ford Ranger";
rather than
var name = "Ford Ranger";
for question number 24 ?