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

If the value of your "variable" doesn't change, it's a constant by definition, and a const declaration is appropriate. If it does change, using const will give you an error. Therefore, it's literally impossible to misuse const in a JavaScript program that runs without errors.


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

Search: