Live data from Hacker News

Rails 7.1 Released

github.com

161–170 of 245 posts

Re: Rails 7.1 Released

#161

Would anyone start a new project with Rails today? If someone suggested using Rails for a new project to me today, I would show them the door. There are so many more mature frameworks in more robust and performant languages. IMO the only reason to use Rails today is if you’re too uncurious to learn something better.

Python is slower than ruby.

Re: Rails 7.1 Released

#162
post #119
post #35

Earlier quoted context omitted.

What happened? I missed the drama.

DHH removed TS from Turbo, posted a pretty inflammatory blog post about it and then got surprised when people reacted badly to it. Classic DHH stuff really.

A significant part of that ""reacted badly"" was a bunch of kids and YouTuber idiots spamming GitHub with meaningless comments, issues and PRs. Those people don't come out of it looking respectable, regardless of DHH's approach.

Re: Rails 7.1 Released

#163

I am Rails dev, and I don't like the fact that Rails in every new version has to REINVENT ALL THE WHEELS, ALL THE TIME. That creates huge problems for Rails devs and stakeholders. Rails is based on Ruby, which is backend language, and Rails should stay more on backend. That means - session management - routing and controllers - many API options (REST, json-rpc, ...) + JSON object exporters - ORM, Mailing, etc - serve…

And chances are, new Rails projects will just be API backends with React frontends. Also, if trying to do lightweight Javascripty frontends within the framework is important, we might as well just move to Phoenix. Phoenix is arguably better already... it just requires a moderate jump to learn Elixir (which unfortunately looks very much like Ruby but requires a very different approach to writing).

Phoenix is super fun, but it is in completely different realm than rails :)

What about all the gems Ruby has, does one really have all he needs inside Elixir/Erlang? More complex stuff like NokoGiri, Haml, etc., that works well and is maintained.

Re: Rails 7.1 Released

#164
post #66

Rails is great, and better than ever. I've spent most of my early years in the field working with Django and Laravel, then moved to frontend doing [all the usual stuff we do nowadays] and this year I was assigned back to a Rails + Hotwire project. I'm truly amazed how much simpler things are. I feel sad most of us have forgotten how easier things could be, and I'm terrified about new people joining this industry that…

I love rails. Hardly anyone is using it in my country, and the companies that do are looking for absolute wizards. Because I can’t find jobs using it, I do t get enough experience and lose out to said wizards (after the jobs stay open for 12+ months). Instead, I’m spewing yet more JS into the world because that’s where the demand is :/

What’s limiting you to taking jobs in just your country? I’ve got a gal working for me in Nepal out of all places. Previously had a guy in Jamaica.

Re: Rails 7.1 Released

#165

Earlier quoted context omitted.

The craziest thing with Elixir is that you can do things all by yourself in the same time that would normally take a big team and consequent infrastructure to do.

As someone who's spent the bulk of his career in Rails and then Phoenix, to me it's the other way around: everything else is just so goddamn slow and unproductive. Don't people realise that it doesn't have to be like this?

Wait, are you saying that you are more productive in Rails than in Phoenix? That seems to be the opposite of what the consensus view in this thread is.

Re: Rails 7.1 Released

#166
I took a 13,000 line Rails 7.0 app and updated it to 7.1. I had to change 1 line of test configuration code to make everything work beyond the diff between 7.0 and 7.1[0].

I would say that's a success for having an easy upgrade path. Now the fun part is going back to refactor some of the code to use the new features in 7.1.

If anyone is curious, I updated my Rails / Docker example app to use 7.1 too https://github.com/nickjj/docker-rails-example. Even though Rails 7.1 comes with a Dockerfile, there's still a lot of opinions you can add such as using Docker Compose to have a fully working out of the box experience that works in development and production -- complete with Postgres, Redis, Action Cable, Sidekiq and more.

[0]: https://railsdiff.org/7.0.8/7.1.0

Re: Rails 7.1 Released

#167
post #2

Currently stuck on a fairly large code base on rails 6 with a ton of react and trying to upgrade to the new “non”-JS way with Hotwire. Wish me luck Rails is great when you stick with the defaults and a land of pain as soon as you leave them.

Loose typing is a nightmare. The youngins always learn the hard way.

Good thing that Ruby is actually strongly typed.

Re: Rails 7.1 Released

#168
post #33

Earlier quoted context omitted.

But why? So many more performant frameworks for this in strongly typed languages to boot.

Which ones? Never saw another one which comes with the same comfort of batteries included like rails. For example having database migrations built in etc.

> For example having database migrations built in etc.

I actually went the exact opposite route, at least when possible: https://github.com/amacneil/dbmate

Pure SQL migrations, regardless of the back end technology that you use, completely decoupled from how each framework/library views things and therefore not dependent on them (you could even rewrite the back end in another technology later on, if needed; or swap ORMs; or avoid issues when there's a major ORM version update).

It's really nice when you can generate entity mappings based on a live database, like with https://blog.jetbrains.com/dotnet/2022/01/31/entity-framewor...

So in my case, I can have:

  * a DB that has migrations applied with dbmate, completely decoupled from any back end(s) that might use it
  * a back end that has entity mappings for ORM (if used) generated from the live local test database container during development, used for an API and not much more
  * a front end that's typically a SPA using the API, but is otherwise just a bunch of prepared files that can be served off of any web server
Of course, if you need SSR then things move around a bit, but that decoupling works great for me (but might not for others)!

Re: Rails 7.1 Released

#169

Earlier quoted context omitted.

This is all about to change. A totally new way of using assets is coming with Propshaft which replaces Sprockets

I honestly can’t tell if your comment is sarcastic because my biggest gripe with Rails is that the asset story changes radically with every major release. Starting with 3.2 and the introduction of the asset pipeline, every new version was “This is all about to change. A totally new way of using assets is coming.” Every new version is supposed to solve all of the problems of the previous version. It’s exhausting to co…

> But my point stands: the prescribed way of handling assets with Rails is ridiculous

What would the alternative be for a 20 year old project?

I think what we're seeing is a natural progression based on how the web changed over the last 2 decades.

I'd be more concerned if Rails didn't change and `rails new` produced a jQuery / SCSS / CoffeeScript loadout and made it difficult to use modern tools. Now it's easier than ever to plug in whatever front-end you want.

Re: Rails 7.1 Released

#170

Earlier quoted context omitted.

As someone who's spent the bulk of his career in Rails and then Phoenix, to me it's the other way around: everything else is just so goddamn slow and unproductive. Don't people realise that it doesn't have to be like this?

Wait, are you saying that you are more productive in Rails than in Phoenix? That seems to be the opposite of what the consensus view in this thread is.

I'm reading it as "Rails and Phoenix is more productive than other technologies".
Post reply on HN