Live data from Hacker News

Don't make me think, or why I switched to Rails from JavaScript SPAs

reviewbunny.app

401–410 of 490 posts

Re: Don't make me think, or why I switched to Rails from JavaScript SPAs

#401
post #297
post #184

Earlier quoted context omitted.

why you see having more than one option as a problem Because some of us are hardwired to choose carefully. If so, when we have to go buy some groceries we just want to get a decent car and drive. The car and driving itself is irrelevant or minutiae, but we can’t tell whether it could take left turns from the start. When there is no decent car by default, we try to be picky about every component, and when it’s almost…

"It may be easy for you" I'm sorry that you understand this from my message. That's not what I meant. good luck with your professionalism.

I think that perfectionism is a downside and coined that “easy for you” as a better mode which everyone would operate in otherwise. But it’s hard to let go of these anxious feelings, so we stick to picky routines (because if you’re not confident, it is unwise to git push). Sorry that my message wasn’t clear enough in this part.

Personally I’m trying to care less when it is reasonable to do, but even the amount of options where to do that in common js stacks is overwhelming.

Re: Don't make me think, or why I switched to Rails from JavaScript SPAs

#402
post #228

Google searches for React and node.js exceed searches for Ruby on Rails by 100% and 50%, respectively [1]. Some people have used this to argue that React/node are more popular than Rails. But I wonder if perhaps this discrepancy appears in Google Trends because it takes more google searches to accomplish the same thing in React/node versus Rails. I feel the Rails ethos of "convention over configuration" allows me to…

As someone who came from other MVC frameworks outside of Ruby, learning Rails has been a cluster-f of searching through documentation circa 2013. The whole rails “convention over configuration makes it easier” is a load of bologna, because the only way to know the “convention” is to either have gone to a rails boot camp, reading the docs top to bottom, or maybe watching rails casts. The best way to work on rails is t…

most rails devs i know started with this guide: https://www.railstutorial.org/

combine that tutorial with skimming the top guides gets someone from 0 to very productive in days or weeks depending on prior experience.

Re: Don't make me think, or why I switched to Rails from JavaScript SPAs

#403
post #369

Earlier quoted context omitted.

I'm your polar inverse: I'm 33 but started coding when I was 4, I've just never worked as a developer (at least not on a team; I've done freelance), and I'm debating making the jump as inflation starts creeping up. I run into the opposite problem: I've played around in frameworks but I don't have the 'years of experience' with them so I worry my resume is going straight in the trash.

4?! I wouldn't worry, all you need is the first job in whatever stack and last a year and you're set

Ha, I had a very nerdy upbringing. My grandfather was obsessed with TVs and ran a side repair business, and then in turn my dad got into micro-computers and PCs. On my mom's side, we've got a bunch of engineers and sci-fi nerds. I learned to type before I could write, and I learned to read by playing things like Dragon Warrior with my dad.

I was also a hyperlexic little weirdo who did things like read the SimEarth manual for fun when I was 5 and decided to explain the differences between prokaryotes and eukaryotes to anybody who would listen. So when we got Web access in '93, I was all in. And I loved getting to do something where all that mattered was how good I was at it, since I was bored senseless in school.

I very much had an upbringing like Larry Page's. I'm just a lot dumber than he is.

Edit: I also doubt you could do that now, on reflection. So much of learning programming is based on feedback and I could only collaborate because nobody asked how old you were and/or if they did, they assumed I was lying. Up until I was about 11, it was assumed I was somebody who just didn't want to share any personal information online/a privacy freak who was making up a stupid answer. "Okay, haha, you're a 7 year old girl. Fine. I won't ask."

Re: Don't make me think, or why I switched to Rails from JavaScript SPAs

#404
post #56

Perhaps I missed it, but the single biggest reason that I moved away from SPAs (such as React) and back to server-side rendering of templates is avoiding having to model my data twice. That’s a lot of overhead. Granted, I’m in the B2B software space, so end-user expectations are those of accuracy, consistency and performance. I imagine expectations (or perhaps priorities) are different for consumer-facing application…

React really has nothing to do with SPA and is only the "V" in MVC. So I'm curious how you were modeling your data in the first place. Since you didn't mention the backend language, I'm going to assume you aren't using node and don't get the benefit of isomorphic code here.

I don't feel it's too much of a stretch to assume that most people doing SPA are probably using node on the server and something like Redux. Then it's a matter of "hydrating" the Redux store + React. Which basically amounts to serialization of the data and passing it to the client via a global variable embedded in the source of the HTML page. When done in this manner, the modelling and fetching of data is identical on the client and the server.

> I’m in the B2B software space

Does your software act like an application? I really feel like B2B is the place to use SPA. You have a login, some sort of dashboard, the user interacts and modifies things. SPA is really slick in this use case. Where SPA falls apart is when you need to present your site as individual pages to Google for SEO and try to get some of the benefits of SPA. That's a nightmare to get right and to maintain.

For B2B I would not use SPA on the marketing, landing, pricing, signup pages and use SPA for the application, itself. Effectively a dual site. Which works really well.

Re: Don't make me think, or why I switched to Rails from JavaScript SPAs

#405

Earlier quoted context omitted.

Sure. And I think what makes Rails and Django shine is they have sound default answers. I’ve yet to see anything in Node that feels like a stable 1:1 replacement. Next.js is excellent, but you still need to sort out a lot of pieces on your own.

Do most people use Django as a server-side framework (no frontend-JS or very minimal JS, may be jQuery)? Or, is it mostly used as an API to interact with the React/Angular/etc front-end framework? What I am trying to get at is do people still build POST-redirect-GET patterns and such for form submissions or they use Django in a more 'modern' way?

From my recent foray into modern Django world, most simple projects and MVP start out as server side like the official guide. Then, when people need some extra frontend magic like React and/or SPA, it's pretty easy to insert into Django. You just include the bundled React/Vue app into a js script still included and served by the same Django route/view/template. Of course, it's also common to start transitioning to Django Rest Framework (DRF) as your API points.

Re: Don't make me think, or why I switched to Rails from JavaScript SPAs

#406
post #275

Earlier quoted context omitted.

If you want to make an app from scratch, you must first understand the universe. This is a ludicrous approach for most. Sure, if you learn from reading and love to read technical manuals, go for it. But to imply this is the best way for most to learn is completely ridiculous.

You don't need to understand universe, just the tools you'll be using to make an app.

You have to build the universe first.

Re: Don't make me think, or why I switched to Rails from JavaScript SPAs

#407
post #228

Google searches for React and node.js exceed searches for Ruby on Rails by 100% and 50%, respectively [1]. Some people have used this to argue that React/node are more popular than Rails. But I wonder if perhaps this discrepancy appears in Google Trends because it takes more google searches to accomplish the same thing in React/node versus Rails. I feel the Rails ethos of "convention over configuration" allows me to…

As someone who came from other MVC frameworks outside of Ruby, learning Rails has been a cluster-f of searching through documentation circa 2013. The whole rails “convention over configuration makes it easier” is a load of bologna, because the only way to know the “convention” is to either have gone to a rails boot camp, reading the docs top to bottom, or maybe watching rails casts. The best way to work on rails is t…

When I learned rails the community had a fundraiser to fund the documentation writing (this was v0.7 or so IIRC). Being able to read the docs sounds like a dream come true.

Re: Don't make me think, or why I switched to Rails from JavaScript SPAs

#408
post #366

Earlier quoted context omitted.

"Reading docs top to bottom" is the answer to this frustration. It's strange that people don't think this is something they should do.

The problem with RoR is that it's an all-encompassing framework. It gives you a huge collection of things you typically don't need — entire major layers like the database are frequently completely irrelevant to projects. This isn't just true of small projects, but can often extend to a large part of a career. One of the grave dangers that older/wiser programmers have learned is to stop trying to pathologically "drink…

> The problem with RoR is that it's an all-encompassing framework. It gives you a huge collection of things you typically don't need — entire major layers like the database are frequently completely irrelevant to projects.

You do know you can just turn off the parts you don’t want, don’t you?

Don’t want database support? Just turn it off or don’t include it in the first place.

Rails doesn’t have to be “special” it just has to get the job done and it does.

Re: Don't make me think, or why I switched to Rails from JavaScript SPAs

#409
post #329

Earlier quoted context omitted.

I wish the Go community had a popular monolith framework that folks rallied behind using when necessary. Unfortunately it's a wild west of bodging together your own routing, config, auth, etc. and nothing is consistent.

Like everything else Google comes up with, just see Android.

To be fair Angular 2+ is designed and operates a lot more like Rails these days.

Re: Don't make me think, or why I switched to Rails from JavaScript SPAs

#410
It has been >7 years since I used RoR for a complex web app. The problem is not configuration vs convention. The problem I had was when I needed dynamic front end functionality for the user (drag and drop, no-refresh edits, etc.) I ended up needing to use another framework/library on the front end too (at that time it was Backbone).

Has that been changed/improved? Or RoR is still primarily used to build server side rendering (SSR) web apps?

Post reply on HN