Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
Gibbon1
on Feb 3, 2025
|
parent
|
context
|
favorite
| on:
Global variables are not the problem
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:
Advantage only the function that depends on the global needs to bring in the dependency.