30 ms·
if any given task is trivial (eg. can be done within minutes manually) author's method is the way I go too. Instead of downloading node.js application with num
by pvtmert 7y ago
if any given task is trivial (eg. can be done within minutes manually) author's method is the way I go too.
Instead of downloading node.js application with numerous dependencies, I also prefer implementing it in few lines of code.
Some can claim running a 'proper' application (like nodejs/express with JWT authentication) is better. But if your business not solely depend on your solution, trivial stuff wins on the long run IMHO.
Of course security/access-control is debatable...
- codazoda 7y agoI am working on a pet project to build a slot machine. I'm looking at it from a regulatory angle as well. As such, I want to understand the code as much as possible. I did some initial tests in Node. When I installed express, for routing, it added tens of dependencies and 2.5MB of code files. They call it "minimal". No thanks. I'll skip the router, for now or write my own.
- hinkley 7y agoI don’t think anyone is suggesting downloading a library is better than writing a single short function. It’s a false dilemma. People who are salty about this subject have dealt with NIH situations where people think they can do better, and are either wrong immediately, or become so when their attention shifts to some other problem. I have written and maintained internal libraries. Many times it’s the wrong choice, sometimes it’s the only choice. But I’m also more responsive to feedback than the NIH bozos my coworkers typically complain about, which may in part be why I get to hear about their grievances. There’s an old half-joke, half-theory that we should elect a President who doesn’t want the job, instead of people who do. You should have the individual contributor who doesn’t want snowflake code write the snowflake code. They’ll keep it no-nonsense.