Live data from Hacker News

Server-Side Only React with Next

webcloud.se

61–70 of 75 posts

Re: Server-Side Only React with Next

#61
post #59

Earlier quoted context omitted.

>> React jobs are still widely available I don't doubt React's effectiveness as an economic tool for job creation. No economic tool is able to turn a simple 1-person job into a complex 100-person job as effectively React does. The Federal Reserve Bank loves React. But is it the most effective tool for writing web apps? Not by a long shot.

> But is it the most effective tool for writing web apps What's your preferred alternative, pray tell?

If you use VueJS without a compiler or bundler during development (and yes, this means no TypeScript), you can achieve an amazingly productive development experience. If you can resist all the tools which try to bait you into adding a bundling step, you won't regret it.

It takes a lot of effort to figure out how to use VueJS without the bundling step and it can feel constraining initially, but the simplicity pays off in the long term.

I'm quite annoyed though that VueJS team has been moving towards TypeScript and bundling. Am I the only person who thinks that front end work is too simple to need type safety?

Front end programming is like riding a bike, after a while, you don't need the training wheels anymore; they just slow you down and deprive you of real enjoyment.

Also, there is a joke my colleagues used to say about front end:

"Front end work is like building a house of cards. If it collapses, no one gets hurt. On the other hand, back end work is like building a house out of wine glasses..."

Re: Server-Side Only React with Next

#62
post #59

Earlier quoted context omitted.

> But is it the most effective tool for writing web apps What's your preferred alternative, pray tell?

If you use VueJS without a compiler or bundler during development (and yes, this means no TypeScript), you can achieve an amazingly productive development experience. If you can resist all the tools which try to bait you into adding a bundling step, you won't regret it. It takes a lot of effort to figure out how to use VueJS without the bundling step and it can feel constraining initially, but the simplicity pays off…

Can't say I agree. The relative cost of bundling is minimal. I don't really think about my setup at all -- it's such a minute part of my daily workflow.

Anyways, your disdain for front-end development will probably preclude a lot of people from taking your stance seriously.

Re: Server-Side Only React with Next

#63
post #58

I'm tired of the dogma that's behind all the hyped up software development tools and techniques. For years, I was telling people that React and related tooling was a bad idea, that it adds a lot of unnecessary bloat which is not worth it. Everyone (like 99% of developers) disagreed with me and kept insisting that it was a simple solution. Fast forward half a decade, now pretty much everyone agrees that React adds a l…

> "simpler solutions are better than complex ones" Everything is a tradeoff. React adds bloat but simplifies development. If any idea should be recited dogmatically it should be "software development is too complicated to live by blanket statements".

>> Everything is a tradeoff

Solutions do have tradeoffs, but if I tell you that breathing is important, we don't really need to discuss tradeoffs...

Simplicity is that important.

I'm getting more this way every year and I've been coding for over 15 years. I'm yet to find the bottom in terms of how simple things should be; things can almost always be made simpler and simplifying things as much as possible nearly always pays off (except if you get paid hourly and care more about salary).

Re: Server-Side Only React with Next

#64
post #23

> In the past I've also tried Jekyll and Hugo. I found that both work great out of the box, but were hard to customize as I'm not very fluent in either Ruby or Go. Why do people not know about Eleventy, why?

I tried looking at the tutorials and docs, but didn't immediately find any mention of images. Does it do images in a sane way, or does it require third-party plugins?

It doesn't. In fact it doesn't do anything for assets in general. But integrating it with Webpack is quite straightforward if you're comfortable with Webpack.

Re: Server-Side Only React with Next

#65
post #62

Earlier quoted context omitted.

If you use VueJS without a compiler or bundler during development (and yes, this means no TypeScript), you can achieve an amazingly productive development experience. If you can resist all the tools which try to bait you into adding a bundling step, you won't regret it. It takes a lot of effort to figure out how to use VueJS without the bundling step and it can feel constraining initially, but the simplicity pays off…

Can't say I agree. The relative cost of bundling is minimal. I don't really think about my setup at all -- it's such a minute part of my daily workflow. Anyways, your disdain for front-end development will probably preclude a lot of people from taking your stance seriously.

If you had actually tried it properly, you would not disagree, it's really that self-evident.

Re: Server-Side Only React with Next

#66
post #57
post #38

Earlier quoted context omitted.

> also less complex. And less interactive.

I always wondered what is not interactive in pressing a form submit button, being brought to another page with results. What is the definition of interactive?

Oh easy. Just try the HTML only version of GMail, I believe you will quickly notice the lack of client side interactivity.

Maybe just a bit of Babylonian language confusion. Static, to dynamic, to server-side-dynamic-vs-client-side-dynamic...

Re: Server-Side Only React with Next

#67
post #62

Earlier quoted context omitted.

Can't say I agree. The relative cost of bundling is minimal. I don't really think about my setup at all -- it's such a minute part of my daily workflow. Anyways, your disdain for front-end development will probably preclude a lot of people from taking your stance seriously.

If you had actually tried it properly, you would not disagree, it's really that self-evident.

If your goal here is just to gloat about how "everyone else is doing it wrong" then I don't think this is a productive conversation. I was doing web development before bundlers were a thing and I do not miss those days.

Re: Server-Side Only React with Next

#68
Every time I read one of these types of articles I have an "Am I taking crazy pills" experience.

I get that as an educational experience this is interesting, but the level of complexity required to generate static html is extraordinary. Just the amount of tooling and conceptual understanding necessary is so crazy.

I've been working on building out a simple Electron app recently and considered React, but realized with little to no interactivity it would be insane overkill. However, one of the most popular boilerplates out there combines react, redux, typescript, webpack, etc, etc.

There seems to be this default right now of 'over-engineering' everything. It's like people have forgotten how to make simple things.

Re: Server-Side Only React with Next

#69

Step 1: Server Side HTML -> Website needs to be more interactive. Step 2: Server Side HTML + Client Side React SPA -> Website is now interactive but performance decreased. Step 3: Server Side HTML + Server Side React + Client Side React SPA -> Website is interactive, performance is good but now it's overly complex. Step 4: Server Side HTML + Server Side React -> Let's make it a bit more simple and even more performan…

No joke, I started my career in Step 1 with Ruby on Rails. I lived and breathed Step 2 and Step 3 with the ever-changing industry standards: jQuery, backbone, angular (avoided), react, and (currently wrangling at work) the complex beast that is graphql & apollo, all over the span of 10 years. Coming back to Rails for a side project has helped me realize:

- Server-side rendering is actually fantastic. It's fast for users and there's no sluggish build step holding you back.

- Turbolinks covers 70% of the interactivity you need.

- Alpine.js covers another 20%.

- With Rails having webpack built in, there's no friction to writing/importing your super-fancy JS interaction for that last 10% when you need to.

Rails gets it right. It truly makes your dev life better, in ways that actually matter. Back then I was convinced Rails led to spaghetti code, but in hindsight I just needed to improve as a software developer.

10 years later, there still isn't a better tool than Rails for tech founders. There are some promising ones, but none that get you launched nearly as quickly. It's kind of annoying, to be honest. Is this that hard of a problem?

Re: Server-Side Only React with Next

#70

Step 1: Server Side HTML -> Website needs to be more interactive. Step 2: Server Side HTML + Client Side React SPA -> Website is now interactive but performance decreased. Step 3: Server Side HTML + Server Side React + Client Side React SPA -> Website is interactive, performance is good but now it's overly complex. Step 4: Server Side HTML + Server Side React -> Let's make it a bit more simple and even more performan…

No joke, I started my career in Step 1 with Ruby on Rails. I lived and breathed Step 2 and Step 3 with the ever-changing industry standards: jQuery, backbone, angular (avoided), react, and (currently wrangling at work) the complex beast that is graphql & apollo, all over the span of 10 years. Coming back to Rails for a side project has helped me realize: - Server-side rendering is actually fantastic. It's fast for us…

Totally agree. I use https://unpoly.com/ instead of Turbolinks, anyone interested in this more sane approach should give it a try.
Post reply on HN