Tech you miss/ new tech trends you hate - ok boomers

I hate that "don't reinvent the wheel" has been taken to it's (il)logical conclusion for programmers. One article I've read was about a javascript npm package called is_promise and how it broke for a few hours. This thing at the time of this post gets 8 million weekly downloads and the whole package is just one function with ONE(1) line of code, and it broke because something completely unrelated to said line of code. I like 3rd party libraries, they make my life easier, but shit like this is surreal.
I'm programming illiterate for the most part, but what the fuck is the use of this in the first place? All it does is check if a program has "ispromise" in it? As in all it does it check for a string of text in the code? Wtf? I have to assume it's just included in some mega bloated library and people aren't downloading it on purpose right?

module.exports = isPromise;
module.exports.default = isPromise;
function isPromise(obj) {
return !!obj && (typeof obj === 'object' || typeof obj === 'function') && typeof obj.then === 'function';
}
That is it?
 
That is it?
Yes. All it does is that you give it a vaguely defined thing and it checks if that thing is of a certain type (a Promise in this instance). It's something that could have been written and tested with some dummy values in 10 minutes tops, but no, we need to slap this into a library, upload it for all to use, and when it brakes it breaks everything depending on it.

I have to assume it's just included in some mega bloated library and people aren't downloading it on purpose right?
Mostly yeah. There's a thing called dependency hell, where you download something and it has a bunch of dependencies, that have a bunch of dependencies of their own, that have a bunch of dependencies of their own, ad infinitum. This is how you get those huge download numbers for something this basic.
 
what the fuck is the use of this in the first place? All it does is check if a program has "ispromise" in it?
Roughly it checks if an object "implements the interface" of a promise, insofar as you could formulate that in JS. If it's an object or a function, and it has a "then()" function, then it's considered enough like a promise.
 
Yes. All it does is that you give it a vaguely defined thing and it checks if that thing is of a certain type (a Promise in this instance). It's something that could have been written and tested with some dummy values in 10 minutes tops, but no, we need to slap this into a library, upload it for all to use, and when it brakes it breaks everything depending on it.


Mostly yeah. There's a thing called dependency hell, where you download something and it has a bunch of dependencies, that have a bunch of dependencies of their own, that have a bunch of dependencies of their own, ad infinitum. This is how you get those huge download numbers for something this basic.
What's the point of checking for a "promise" though? Is it some T&S bs or is it an actual term for some specific use?
 
  • Dumb
Reactions: args
There's also the thing with 50Hz mode still not being an option on quite a few smartphone cameras, purely because every fucking website online just re-encodes 25FPS to 29.97FPS jankily, and of course three quarters of the planet should just deal with flickery lighting shite in their pictures and videos.
I don't want to be pro-American for the sake of it, but whoever standardized a higher framerate deserves to dominate. Get fucked.
 
  • Like
  • Feels
Reactions: Wright and seri0us
But why has it persisted into the digital era?
Because standards are persistent even when the reason for them is gone.
Veggies that had taste, especially tomatoes.
Utterly fuck what these assholes have done to tomatoes. They might as well be wax fruit and are completely unsuitable for making anything at all with other than maybe slicing them to put on a burger. To get decent tomatoes, you need to go to a farmer's market, super fancy produce specialist store (and pay out the ass), or grow them yourself.

What they do is pick them green and unripe, and then treat them with ethylene gas to fake ripeness by turning them red, but for all the taste they have they might as well be made of wax.
 
I don't like this trend of software on Linux using their own updating mechanisms and/or packaging like flatpak. In my opinion, there's only three ways software should be distributed on Linux: through repositories, actual packages like deb files, or via source code. But this new trend spits in the face of everyone else who have worked hard over the decades to create top-notch software management: maintainers, developers, and end users. Keep the nightmare of software management to Windows!
 
Back