Hacker News new | ask | show | jobs
by threethirtytwo 151 days ago
Functions are rarely used this way, it’s bad practice. Typically when this is done the mutating state is scoped in an object and the function is not called a “function” it’s called a method.