Live data from Hacker News

The case for frameworks

seldo.com

61–70 of 91 posts

Re: The case for frameworks

#61
post #3

Until you’ve hit product market fit, you shouldn’t build anything other than what is unique to your product. If you are spending time on authentication or forms or worker queue architecture, you’re wasting time. Frameworks and plug-ins exist to allow this to be all plug and play, so you can focus on building something potentially useful enough for people to pay for it. Product market fit is generally achieved when yo…

This argument reminds me of people who confuse market success with product quality. I.e. some people believe that if the product sells well, then it must be a good product. You don't need to try hard to convince yourself that there's no causal link between the two (eg. fast food sells well, but isn't good food, high-end goods usually don't sell well because buyers aren't willing to pay extra for marginal improvements…

Exactly, the point of frameworks like React is to patch over issues with html, css, javascript and the DOM. Dropping React (the framework) will just make you deal with those issues in particular ways that only you understand, but it won't make them disappear.

Re: The case for frameworks

#62
I think the original point of the discussion is somewhat lost, which is not frameworks, it's shipping too much JS to the client which in particular hurts on Android.

Whilst I strongly agree SPAs are overused, let's take a moment to consider this sorry state of affairs. It's 2023 and when you ship some 50-200KB of executable code, you're in the red.

This is like 1/7th of a damn floppy disk, which I've lived through. Mobile apps are hundreds of MB in size, and we're supposed to compete with that using sticks and stones. Recently my Razor mouse had a driver update, it was 2GB in size. We learn about Unity on desktop, now able to render 17 trillion polygons per second yet we struggle to render some state and squares on the mobile web.

That's the real issue. Big parts of the mobile web are severely underpowered yet we still want to ship the "rich application" paradigm to them. Worse, without web standards offering anything remotely useful for this model.

That said, the idea that SPAs offer a superior experience that users are somehow demanding is bullshit when you consider how a typical SPA works. Consider a simple navigation action (route change) where the standard argument in favor of SPAs is that these are much faster compared to a traditional server-side page reload.

First, the SPA might need to load a new bundle, as tree shaking is the best practice where you lazily load per route code. This client code needs to be downloaded, parsed and executed, before anything even starts to happen. Next, the route-specific components mount. Many will require remote data, so at this point the page change may feel fast, it's useless and will remain useless until all remote network calls are resolved.

Compare this to a traditional, well-optimized MPA. You navigate to another route. The server will come back with ALL data/state resolved as well as all rendering (HTML) already done. And as this server response comes in, the browser is already working on the DOM layout/paint process, which is not true for a REST call. Plus, back/forward works reliably, scroll position works, memory leaks are no issue nor are stale tabs.

It's really debatable whether the SPA has the better experience or that users demand it. The point is to deliver meaningful content and interactions, that's the true value of whatever you are building. As such, I think the new wave of SSR/hybrid frameworks are a step in the right direction.

Re: The case for frameworks

#63
post #61

Earlier quoted context omitted.

This argument reminds me of people who confuse market success with product quality. I.e. some people believe that if the product sells well, then it must be a good product. You don't need to try hard to convince yourself that there's no causal link between the two (eg. fast food sells well, but isn't good food, high-end goods usually don't sell well because buyers aren't willing to pay extra for marginal improvements…

Exactly, the point of frameworks like React is to patch over issues with html, css, javascript and the DOM. Dropping React (the framework) will just make you deal with those issues in particular ways that only you understand, but it won't make them disappear.

That’s strange, I thought the point of React was to make websites slow and laggy so you can save on server costs by just serving json after the initial payload.

Re: The case for frameworks

#64
post #63
post #61

Earlier quoted context omitted.

Exactly, the point of frameworks like React is to patch over issues with html, css, javascript and the DOM. Dropping React (the framework) will just make you deal with those issues in particular ways that only you understand, but it won't make them disappear.

That’s strange, I thought the point of React was to make websites slow and laggy so you can save on server costs by just serving json after the initial payload.

Some of us still remember the golden years of doing the same but with jQuery snippets spread through hundreds of files with zero logical connection between them except in the developer's mind.

Re: The case for frameworks

#65
post #64
post #63

Earlier quoted context omitted.

That’s strange, I thought the point of React was to make websites slow and laggy so you can save on server costs by just serving json after the initial payload.

Some of us still remember the golden years of doing the same but with jQuery snippets spread through hundreds of files with zero logical connection between them except in the developer's mind.

It's not even ancient history. React is only 10 years old.

Re: The case for frameworks

#66
post #64
post #63

Earlier quoted context omitted.

That’s strange, I thought the point of React was to make websites slow and laggy so you can save on server costs by just serving json after the initial payload.

Some of us still remember the golden years of doing the same but with jQuery snippets spread through hundreds of files with zero logical connection between them except in the developer's mind.

I have no issues with frameworks and libs but the fact I know I’m on site built with react because everything gets laggy and my laptops fans start spinning is not a great selling point.

Re: The case for frameworks

#67
post #3

Until you’ve hit product market fit, you shouldn’t build anything other than what is unique to your product. If you are spending time on authentication or forms or worker queue architecture, you’re wasting time. Frameworks and plug-ins exist to allow this to be all plug and play, so you can focus on building something potentially useful enough for people to pay for it. Product market fit is generally achieved when yo…

Agreed. I posted this comment a few years ago, but it looks like it's relevant as here as well: A potential acquisition came our way that seemed to be exactly what we were looking for. Customer traction and revenues, the features exactly what we were looking to overhaul. There was very high internal interest in acquiring the technology and the company. The need for this set of features was so high and the internal de…

Did they at least use something like jquery or was it all bespoke code?

Re: The case for frameworks

#68
post #3

Until you’ve hit product market fit, you shouldn’t build anything other than what is unique to your product. If you are spending time on authentication or forms or worker queue architecture, you’re wasting time. Frameworks and plug-ins exist to allow this to be all plug and play, so you can focus on building something potentially useful enough for people to pay for it. Product market fit is generally achieved when yo…

Prior to product market fit you should take the shortest possible path to delivering your essential feature set. You have a short runway and if you hit the end, it's game over.

That path may or may not involve a framework. One common developer mistake is to use a framework not because it will save time, but because it's a brand name and they think it'll save them from having to learn about a particular problem space.

For example, any developer should be able to build a simple task queue in a couple of days. You can read about how they work, find a simple example or two, and code one. Will it have lots of features? No. Will it scale? No. Does any of this matter before you have product market fit? No.

Along the way you make sure you have good separation of concerns in your overall architecture, so that _if_ it turns out there are many actual humans who want to pay for this idea, you can swap out what you wrote and replace it with something better.

As a bonus, by the time this happens you'll understand task queues (and in particular what your product needs one for) very well. So picking and implementing the right framework will be easy.

If a framework is the easiest way to get to something the market can validate, use it! If it's not, don't.

It's really not that hard to understand how any of the common building blocks of a modern web app works. To understand it deeply, sure, that may take 20 years, but at PMF that depth is not critical yet.

Let's be honest - 80% of the time when we talk about doing things "right" we are really talking about concurrency and scale. Premature optimization is the root of all evil and so on...

Re: The case for frameworks

#69
post #66
post #64

Earlier quoted context omitted.

Some of us still remember the golden years of doing the same but with jQuery snippets spread through hundreds of files with zero logical connection between them except in the developer's mind.

I have no issues with frameworks and libs but the fact I know I’m on site built with react because everything gets laggy and my laptops fans start spinning is not a great selling point.

Yes, the web is a terrible platform for applications. Anything on the web that goes beyond the equivalent of linked PDFs will be wonky.

There's nothing on the web even approaching 1990s desktop applications. Specially if you care about latency, precision, and text inputs not randomly eating what you type.

Even with the wonkiness, the web is usually worth using because of the access you get to big amounts of data and backend servers providing nice services.

Re: The case for frameworks

#70
post #3

Until you’ve hit product market fit, you shouldn’t build anything other than what is unique to your product. If you are spending time on authentication or forms or worker queue architecture, you’re wasting time. Frameworks and plug-ins exist to allow this to be all plug and play, so you can focus on building something potentially useful enough for people to pay for it. Product market fit is generally achieved when yo…

Prior to product market fit you should take the shortest possible path to delivering your essential feature set. You have a short runway and if you hit the end, it's game over. That path may or may not involve a framework. One common developer mistake is to use a framework not because it will save time, but because it's a brand name and they think it'll save them from having to learn about a particular problem space.…

> Along the way you make sure you have good separation of concerns in your overall architecture, so that _if_ it turns out there are many actual humans who want to pay for this idea, you can swap out what you wrote and replace it with something better.

This is the key right here. Very little else matters. Where a lot of companies get this wrong is they either go the route of picking a minimal framework and writing everything in-house only to have created a very unique monster that took a lot of time at the end or they go all in on frameworks without identifying the bottlenecks as they go along and they wait until its too late to make an easy transition.

Post reply on HN