Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Aren't local variables scoped to be visible within the entire JavaScript function? I thought the recommendation to declare local variables at the top the function was a reminder (or to avoid accidental importing of global variables of the same name)?


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: