Comments on: Javascript Function Declarations, Function Expressions and Object Literals https://activatesaga.com/javascript-function-declarations-function-expressions-object-literals/ ActivateSaga. Content for Web Artisans. Mon, 08 Apr 2024 09:15:10 +0000 hourly 1 https://wordpress.org/?v=4.8.24 By: tysweezy https://activatesaga.com/javascript-function-declarations-function-expressions-object-literals/#comment-17113 Fri, 21 Nov 2014 22:26:00 +0000 http://activatesaga.com/?p=110#comment-17113 Yeah, that makes sense. Looking back at this, I think each way gets executed differently at runtime don’t they?

Thanks for your comment. You are awesome! 🙂

]]>
By: Larry Eliemenye https://activatesaga.com/javascript-function-declarations-function-expressions-object-literals/#comment-17112 Fri, 21 Nov 2014 21:22:00 +0000 http://activatesaga.com/?p=110#comment-17112 Function declaration and expressions are different because of the way the javascript interpreter treats functions and variables. Functions get memory allocations first before variables during the activation stage of the execution context and expressions are just variables so they get allocated last.

]]>