JavaScript Associate — Easy
Key points
- Hoisting applies to both variables and functions
- Declarations are moved to the top of their scope during the compilation phase
- Only the declarations are hoisted, not the initializations
- Helps in avoiding reference errors in the code
Ready to go further?
Related questions
