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

I tend to use getter and setter functions to access globals and manage state.

Advantage only the function that depends on the global needs to bring in the dependency.



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

Search: