Hacker News new | ask | show | jobs
by zackify 1890 days ago
It’s interesting to see people feel this way about JS.

Lately I’ve been trying to learn kotlin... and man... that stuff (gradle) adds a weird amount of boilerplate to everything.

JS / TS on the other hand. It’s a package.json, or tsconfig. Not much else is required.

Jump into deno and you don’t even need those. Feels like JS is one of the better languages in this regard

3 comments

My interactions with Gradle have been with Android, and... oh boy do I hate it.

It's a noticeably-more-concise-and-flexible option than what came before it, and the net result has probably been good. But it's next to impossible to understand and troubleshoot when things don't go perfectly. And similarly difficult to figure out what you need to do to achieve X, because who knows, it could be in any of thousands of locations, called anything, and there's not enough structure to let you infer what's reasonable and what isn't.

What's the weird amount of boilerplate in gradle compared to package.json + tsconfig (+ webpack.config.js or next.config.js, + jest.config.js, + babel.config.js, + workspaces) ?
They're used to one, but new to another.
while I agree on kotlin (or java, or swift, or objective c), I think early releases of node.js or frontend development pre big frameworks were much better in that regard.

We're still not as bad as mobile development, but things are getting worse.

Have you tried esbuild. IMO it's a big step back in the right direction. We're not quite ready to switch to it on the frontend, but we're using it for our node.js (typescript) code. Configuration is 2 lines, and most of that's specifying which files to compile!