Hacker News new | ask | show | jobs
by dncornholio 1502 days ago
> if you encounter it frequently enough

That's a huge if!

So abstracting a one line in a function is actually good. Putting it up on npm is debatable.