Live data from Hacker News

Ask HN: Getting tired of complexity in web development

news.ycombinator.com

241–250 of 292 posts

Re: Ask HN: Getting tired of complexity in web development

#241

Earlier quoted context omitted.

> - no state (which also means no memory leaks), Ehh, what? Sessions are state. > - just drop a file on web server and it works (no crazy CI pipeline) Except when I have to set-up php-fpm, opcache and configure countless parameters in php.ini. > - the documentation is fantastic, Yes, but I still have to check it for useless constructs like "mysql_real_escape_string" vs "mysql_escape_string" which should have never ex…

> Sessions are state Is database state? > php-fpm, opcache Nope > countless parameters Certainly not > "mysql_real_escape_string" vs "mysql_escape_string" There are only a handful of these, and you can learn about them with a simple google search.

> Is database state?

Duh. I'm talking specifically about session_*. This data isn't magically stored in the air and if you use more than a single machine, you need to implement the SessionHandlerInterface with a solution like redis or memcached in a clustered setup. That's literally the same as using any other language, plus such map-reduce kv stores.

Since you mention that I wouldn't need php-fpm and opcache, I assume that you haven't worked at scale with php. php might be a good fit as long as you don't have any users, but this isn't true for everyone.

Re: Ask HN: Getting tired of complexity in web development

#243
post #196
post #27

Earlier quoted context omitted.

Oh god ORM's, pointless waste of time and just an excuse not to learn SQL.. almost as bad as the #1 PHP fallacy; Smarty (which is still a thing).

I will be bias here as I made my own ORM (for typescript and postgre, no less), but I have to hard disagree. As other comments have pointed out, ORMs are about productivity, getting persistence done quickly. Also what you just said is widely applicable - by your thinking, all programming languages are "a waste of time" and an excuse to not learn how to write binary files/machine code by hand? Also, it doesn't have to…

“ Also, it doesn't have to be black and white - ORM or no ORM

The sad state of the php world is that there is no other option but to use it. If something is on fashion then it _must_ be adopted. Writing your own is considered insanity and so is taking a different path than the mass, regardless of for good reason or not.

Re: Ask HN: Getting tired of complexity in web development

#244
After jumping like a flea between frameworks for, what, 10 years (was an amateur dev), I came to the conclusion that I will use one well maintained framework for everything.

I settled on Quasar (based on Vue and recently also Vite).

If I need to have [a page with a button | anything really] I will use Quasar (and Typescript).

Yes, it is overkill. Yes, it is not lean. Yes, it is simpler to do it in 5 lines of vanilla JS.

But OTOH I always know what I will get, do not need to guess, know the time it will take me to write something.

And, notably, frees me from thinking what to use now. I have the hammer for anything that remotely looks like a nail, even if it is actually a screw.

Re: Ask HN: Getting tired of complexity in web development

#245

I call this the "path to enlightenment." You have discovered that the most popular toolchain is overkill for 95% of the things its used for. The problem is that's true literally across the board. You move to the backend and you have to deal with people who fell in love with microservices and weird databases that they didn't need. You move to ops and you have to deal with k8s when a single container would do. If you t…

> Why does this happen?

These teams lack technical leadership that is based on professional experience. This is the sort of lesson that is acquired after at least 10 if not more years of professional work, however the industry tests for algorithmic performance art on whiteboards to select software engineers.

Re: Ask HN: Getting tired of complexity in web development

#246
OK, so I am late to the party, but I have some thoughts.

One, if you search for the word complicated on HN, the top hit is the same complaint from 2019. This isn't getting better. https://news.ycombinator.com/item?id=20637849

Two, from the discussion in February, web development is literally the worst job in the USA for degree of change in complexity / lack of ability to build career capital over time. This is (and will in the future) driving talented people out of the profession. https://news.ycombinator.com/item?id=24910949 https://whoisnnamdi.com/never-enough-developers/

Three, I have a pet theory. Indulge me. We have noted before that there is a lot of overlap between software engineering contracting and, say, carpentry. Key difference: once a cabinet is done, it's done. There isn't any need for follow up, enhancements, new requirements, changes. However, if you make a software project so complicated that only you or someone with very similar experience can make changes to it, you drive up the likelihood of capturing the benefit of a future income stream. This is also the impetus behind very complicated frameworks: the more people adopt your complicated solution, the more likelihood they drive business towards you.

Lastly, this crowd isn't going to like this, but the solution in other engineering disciplines is standardisation and opinionated off the shelf solutions. It's that or wrestling with complexity forever.

Re: Ask HN: Getting tired of complexity in web development

#247

I call this the "path to enlightenment." You have discovered that the most popular toolchain is overkill for 95% of the things its used for. The problem is that's true literally across the board. You move to the backend and you have to deal with people who fell in love with microservices and weird databases that they didn't need. You move to ops and you have to deal with k8s when a single container would do. If you t…

In addition to what the other commenter says about wanting to postpone the 'creative' aspect of the work, I'd also say this happens because of:

1. Boredom. Everyone wants to be doing interesting work, and doing the same thing that's been done a million times before is probably pretty dull. Devs don't want to feel like code monkeys piecing things together assembly line style, even if that's exactly what's needed for many sites, apps, etc.

2. CV/Resume padding. Perhaps many people see every job as a stepping stone to the next one, and hope a complex solution will get them hired at a FAANG company or fast growing startup in future.

3. Expectations. Problems at large tech companies like Google are more likely to be documented online, since the folks working there tend to have more of an online/social media/blog presence than the folks doing 9-5s at more traditional companies. So people think "hey, if this is how others are doing it, this must be the proper way to do it", ignoring the fact that it's the proper way for a company expecting X billion users a year rather than a more reasonable number.

4. Ego/online reputation. Saying you used a fancy framework and hosting setup with microservices for your project gets a lot more votes on Reddit and Hacker News than saying you used say, basic HTML and CSS.

5. Lack of training/learning opportunities at work. Companies tend not to give workers much of a chance to learn new tech or work on interesting projects in work hours, which would provide them a place to experiment with these new technologies. So they try and integrate it into their normal work instead, even if it's completely the wrong solution for the problem at hand.

Re: Ask HN: Getting tired of complexity in web development

#248
> I have a few years of experience working mostly on the frontend with React and am getting more and more frustrated with all the added layers of complexity needed to work with most common frontend frameworks.

It's complicated because you (or your team) are using very, very low level tools, which were made for large teams, working at large companies with complex architectures adapted to fit more people working on the problem, with large budgets where all of this can be afforded. In fact, you might need to use those low level tools in most of those environments. I'm talking about React, GraphQL, SPA architecture, microservices built with microframeworks (some times in pretty low level languages for the Web such as Go, etc...)

Try Rails, Laravel or, if you want to stay in the JavaScript world: Adonis.js. Pick a modern "sprinkles" library for the parts you need interactivity such as htmx, unpolyor alpinejs (or Hotwire if using Rails). And boom... Everything is simple again. Just not trendy and fashion.

Re: Ask HN: Getting tired of complexity in web development

#249
post #225
post #121

Earlier quoted context omitted.

Spot on. Rails just let you get shit done. All we needed was a Rails for Node.js.

There is a Laravel for Node.js - https://adonisjs.com/

+1 for Adonis. I've been using it for some time, together with unpoly + alpinejs and it's a real pleasure. I'm really productive with this stack. In fact, their docs site is built using these tools: https://github.com/adonisjs/docs.adonisjs.com/blob/develop/p...

Re: Ask HN: Getting tired of complexity in web development

#250
post #4

Using React with an API back-end is only 1 of many choices. There's tools like Hotwire[0] and htmx[1] (both are back-end agnostic) that will let you create good old boring web apps with any back-end language where you don't need to write a ton of JS. You can sprinkle in front-end quality of life enhancements as needed to make nice feeling web apps with reasonably minimal complexity. [0]: https://hotwired.dev/ [1]: ht…

Don't forget Unpoly: https://demo.unpoly.com/

Unpoly is the best thing I've discovered in the frontend world in the last 5 years. It's a breath of fresh air when compared to all the crazyness going on.

I use it to replace almost all "api" calls to the backend and for the "turbolinks like" navigation, modals, etc. Then I use Alpinejs for the really interactive/complex parts.

I'm not doing a React/SPA ever again if I have any chance to decide on that.

Post reply on HN