this in the Global Context

InstructorMarius Schulz

Share this video with your friends

Send Tweet

JavaScript's this mechanism behaves a little differently compared to other languages. When used in the global context (outside of any function), this refers to the global object. This lesson highlights the different behavior between Node and the browser.

Tengjiao
~ 7 years ago

simple but useful, thanks

Tengjiao
~ 7 years ago

simple but useful, thanks

Alicia
~ 7 years ago

Off topic, but what sort of text editor/terminal configuration is that? It looks lovely. :)

Marius Schulzinstructor
~ 7 years ago

@Alicia: I'm using Visual Studio Code with the Dracula theme. A lovely combination, indeed :)